Skip to content

Commit

Permalink
ACPI: PCC: Fix unintentional integer overflow
Browse files Browse the repository at this point in the history
Fix an unintentional u32 overflow by changing PCC_CMD_WAIT_RETRIES_NUM
to 500ULL.

Fixes: 91cefef ("ACPI: PCC: replace wait_for_completion()")
Signed-off-by: Manank Patel <pmanank200502@gmail.com>
Acked-by: Sudeep Holla <sudeep.holla@arm.com>
Acked-by: Huisong Li <lihuisong@huawei.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
  • Loading branch information
Manank Patel authored and Rafael J. Wysocki committed Oct 26, 2022
1 parent 247f34f commit 8338b74
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/acpi/acpi_pcc.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
* Arbitrary retries in case the remote processor is slow to respond
* to PCC commands
*/
#define PCC_CMD_WAIT_RETRIES_NUM 500
#define PCC_CMD_WAIT_RETRIES_NUM 500ULL

struct pcc_data {
struct pcc_mbox_chan *pcc_chan;
Expand Down

0 comments on commit 8338b74

Please sign in to comment.