nvmem-reboot-mode: support small reboot mode magic
Get series with b4
b4 am [email protected]Versions newest first
- v4 Latest2 patches 2 repliesIn review
Changes in v4 from the cover letter
- Excluded one patch which was accepted from v3 [1]:
"nvmem: core: improve range check for nvmem_cell_write()"
- Handle truncation of the reboot mode magic in nvmem-reboot-mode instead of in nvmem core.
- Introduced nvmem_cell_size().
Patches in v4 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | nvmem: core: add nvmem_cell_size()drivers/ include/ | +24 | 2 replies | |
| 2/2 | power: reset: nvmem-reboot-mode: support smaller magicdrivers/ | +8 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v4 yet.
Cover letter [PATCH v4 0/2] nvmem-reboot-mode: support small reboot mode magic
Hi all,
These patches allow nvmem-reboot-mode to handle devices with a reboot-mode cell smaller than 4 bytes, such as Qualcomm SA8775P. Without this change, nvmem_reboot_mode_write() tries to write 4 bytes to a 1-byte nvmem cell and fails with the message "update reboot mode bits failed" on affected devices.
This issue previously resulted in an out-of-bounds heap write but, after one of my patches from v3 of this series was accepted, it results in that error message instead.
[1]
https://lore.kernel.org/all/[email protected]/
v4:
- Excluded one patch which was accepted from v3 [1]:
"nvmem: core: improve range check for nvmem_cell_write()"
- Handle truncation of the reboot mode magic in nvmem-reboot-mode instead of in nvmem core.
- Introduced nvmem_cell_size().
v3:
- Accepted suggestion for changing nvmem_cell_write bounds check
v2:
- Added missing function definition for CONFIG_NVMEM=n
Jennifer Berringer (2):
nvmem: core: add nvmem_cell_size()
power: reset: nvmem-reboot-mode: support smaller magic
drivers/nvmem/core.c | 18 ++++++++++++++++++ drivers/power/reset/nvmem-reboot-mode.c | 9 ++++++++- include/linux/nvmem-consumer.h | 6 ++++++ 3 files changed, 32 insertions(+), 1 deletion(-)
base-commit: ffd294d346d185b70e28b1a28abe367bbfe53c04
Signature · 1 line
2.47.1