ACPI: IORT: Add extra message "applying workaround" for off-by-1 issue
Subsystems (2)
Hanjun Guo
maintainerPATCH 1/1 ACPI: IORT: Add extra message "applying workaround" for off-by-1 issue
As we already applied a workaround for the off-by-1 issue, it's good to add extra message "applying workaround" to make people less uneasy to see such message in the boot log.
---
Based on top of for-next/acpi branch of ARM64 repo
drivers/acpi/arm64/iort.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/acpi/arm64/iort.c +1 -1
@@ -328,7 +328,7 @@ static int iort_id_map(struct acpi_iort_id_mapping *map, u8 type, u32 rid_in,* Otherwise, things are *really* broken, and we just disregard * duplicate matches entirely to retain compatibility. */ -pr_err (FW_BUG "[map %p] conflicting mapping for input ID 0x%x\n" , +pr_err (FW_BUG "[map %p] conflicting mapping for input ID 0x%x, applying workaround\n" , map, rid_in);if (rid_in != map->input_base)return -ENXIO ;
Signature · 1 line
1.7.12.4
Quoted 6 lines · Hanjun Guo
As we already applied a workaround for the off-by-1 issue, it's good to add extra message "applying workaround" to make people less uneasy to see such message in the boot log.
Signed-off-by Hanjun Guo <[email protected]>
Hi Hanjun,
Quoted 12 lines
---
Based on top of for-next/acpi branch of ARM64 repo
drivers/acpi/arm64/iort.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/acpi/arm64/iort.c +0
-0
drivers/acpi/arm64/iort.c static int iort_id_map(struct acpi_iort_id_mapping *map, u8 type, u32 rid_in, · line 331
Quoted 5 lines
drivers/acpi/arm64/iort.c +1
-1@@ -328,7 +328,7 @@ static int iort_id_map(struct acpi_iort_id_mapping *map, u8 type, u32 rid_in,* Otherwise, things are *really* broken, and we just disregard * duplicate matches entirely to retain compatibility. */ - pr_err(FW_BUG "[map %p] conflicting mapping for input ID 0x%x\n", + pr_err(FW_BUG "[map %p] conflicting mapping for input ID 0x%x, applying workaround\n",
This is not correct. The workaround is only applied if rid_in == map->input_base, so better to print a second line after the 'return' below that is only reached in that particular case.
Quoted 6 lines
drivers/acpi/arm64/iort.c +0
-1map, rid_in);if (rid_in != map->input_base)return -ENXIO ; --1.7.12.4
Hanjun Guo
maintainerHi Ard,
Quoted 17 lines · Ard Biesheuvel
Quoted 6 lines · Hanjun Guo
As we already applied a workaround for the off-by-1 issue, it's good to add extra message "applying workaround" to make people less uneasy to see such message in the boot log.
Signed-off-by Hanjun Guo <[email protected]>Hi Hanjun,
Quoted 7 lines
---
Based on top of for-next/acpi branch of ARM64 repo
drivers/acpi/arm64/iort.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Quoted 14 lines
drivers/acpi/arm64/iort.c static int iort_id_map(struct acpi_iort_id_mapping *map, u8 type, u32 rid_in, · line 331
Quoted 10 lines
drivers/acpi/arm64/iort.c +1
-1@@ -328,7 +328,7 @@ static int iort_id_map(struct acpi_iort_id_mapping *map, u8 type, u32 rid_in,* Otherwise, things are *really* broken, and we just disregard * duplicate matches entirely to retain compatibility. */ - pr_err(FW_BUG "[map %p] conflicting mapping for input ID 0x%x\n", + pr_err(FW_BUG "[map %p] conflicting mapping for input ID 0x%x, applying workaround\n",This is not correct. The workaround is only applied if
rid_in==map->input_base, so better to print a second line after the 'return' below that is only reached in that particular case.
Obvious I'm wrong, I will update this patch, thanks a lot!
Quoted 10 lines
Quoted 7 lines
drivers/acpi/arm64/iort.c +0
-1map, rid_in);if (rid_in != map->input_base)return -ENXIO ; --1.7.12.4
.
Hanjun Guo
maintainerQuoted 38 lines · Hanjun Guo
Hi Ard,
Quoted 26 lines · Ard Biesheuvel
Quoted 6 lines · Hanjun Guo
As we already applied a workaround for the off-by-1 issue, it's good to add extra message "applying workaround" to make people less uneasy to see such message in the boot log.
Signed-off-by Hanjun Guo <[email protected]>Hi Hanjun,
Quoted 16 lines
---
Based on top of for-next/acpi branch of ARM64 repo
drivers/acpi/arm64/iort.c| 2 +-1 file changed, 1 insertion(+), 1 deletion(-)drivers/acpi/arm64/iort.c +0
-0@@ -328,7 +328,7 @@ static int iort_id_map(structacpi_iort_id_mapping *map, u8 type, u32 rid_in, * Otherwise, things are *really* broken, and we just disregard * duplicate matches entirely to retain compatibility. */ Quoted 8 lines
drivers/acpi/arm64/iort.c static int iort_id_map(struct · line 334
Quoted 4 lines
drivers/acpi/arm64/iort.c +1
-1- pr_err(FW_BUG "[map %p] conflicting mapping for input ID 0x%x\n", + pr_err(FW_BUG "[map %p] conflicting mapping for input ID 0x%x, applying workaround\n",This is not correct. The workaround is only applied if
rid_in==map->input_base, so better to print a second line after the 'return' below that is only reached in that particular case.
Quoted 1 line
Obvious I'm wrong, I will update this patch, thanks a lot!
By the way, how about the print below? Should I add something more?
if (rid_in != map->input_base)
return -ENXIO;+
+ pr_err(FW_BUG "applying workaround for the conflicting mapping\n");
Thanks
Hanjun
Quoted 49 lines · Hanjun Guo
Quoted 39 lines · Hanjun Guo
Hi Ard,
Quoted 27 lines · Ard Biesheuvel
Quoted 6 lines · Hanjun Guo
As we already applied a workaround for the off-by-1 issue, it's good to add extra message "applying workaround" to make people less uneasy to see such message in the boot log.
Signed-off-by Hanjun Guo <[email protected]>Hi Hanjun,
Quoted 17 lines
---
Based on top of for-next/acpi branch of ARM64 repo
drivers/acpi/arm64/iort.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/acpi/arm64/iort.c +0
-0@@ -328,7 +328,7 @@ static int iort_id_map(struct acpi_iort_id_mapping *map, u8 type, u32 rid_in, * Otherwise, things are *really* broken, and wejust disregard
* duplicate matches entirely to retain compatibility. */Quoted 8 lines
Quoted 4 lines
- pr_err(FW_BUG "[map %p] conflicting mapping for input
ID 0x%x\n",
+ pr_err(FW_BUG "[map %p] conflicting mapping for input
ID 0x%x, applying workaround\n",This is not correct. The workaround is only applied if
rid_in==map->input_base, so better to print a second line after the 'return' below that is only reached in that particular case.Quoted 1 line
Obvious I'm wrong, I will update this patch, thanks a lot!
By the way, how about the print below? Should I add something more?
if (rid_in != map->input_base) return -ENXIO;(quoted diff) +2
-0+ + pr_err(FW_BUG "applying workaround for the conflicting
Quoted 2 lines
mapping\n");
Simply 'applying workaround' should do it imo.