diff options
| author | Stanley Chang <[email protected]> | 2023-08-01 15:14:52 +0800 |
|---|---|---|
| committer | Greg Kroah-Hartman <[email protected]> | 2023-08-04 14:47:18 +0200 |
| commit | 2569088dbaaff6401630bda517db2e1ac4d92692 (patch) | |
| tree | c67620f1552c70fbc0f20dd65281717c22040044 /tools/perf/scripts/python | |
| parent | e2fa03ec60f6313ff7cedce7119e6fbab06a8534 (diff) | |
phy: realtek: usb: add the error handler for nvmem_cell_read
There are following smatch warning:
drivers/phy/realtek/phy-rtk-usb2.c:901 get_phy_data_by_efuse()
error: 'buf' dereferencing possible ERR_PTR()
drivers/phy/realtek/phy-rtk-usb2.c:942 get_phy_data_by_efuse()
error: 'buf' dereferencing possible ERR_PTR()
drivers/phy/realtek/phy-rtk-usb3.c:460
get_phy_data_by_efuse() error: 'buf' dereferencing possible ERR_PTR()
The nvmem_cell_read may fail to read. So, driver must handle failure cases.
Fixes: 134e6d25f6bd ("phy: realtek: usb: Add driver for the Realtek SoC USB 2.0 PHY")
Fixes: adda6e82a7de ("phy: realtek: usb: Add driver for the Realtek SoC USB 3.0 PHY")
Reported-by: Dan Carpenter <[email protected]>
Closes: https://lore.kernel.org/linux-phy/[email protected]/
Signed-off-by: Stanley Chang <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions