Re: [PATCH][next] mailbox: PCC: check for negative count for parse failure checking

2018-05-30 Thread Dan Carpenter
On Wed, May 30, 2018 at 06:14:29PM +0100, Colin King wrote: > From: Colin Ian King > > The function acpi_table_parse_enties_array can potentially return a > negative value if parsing fails. Currently the check on the return > is not checking for errors, so fix this by adding a -ve check too. >

Re: [PATCH][next] mailbox: PCC: check for negative count for parse failure checking

2018-05-30 Thread Dan Carpenter
On Wed, May 30, 2018 at 06:14:29PM +0100, Colin King wrote: > From: Colin Ian King > > The function acpi_table_parse_enties_array can potentially return a > negative value if parsing fails. Currently the check on the return > is not checking for errors, so fix this by adding a -ve check too. >

Re: [PATCH][next] mailbox: PCC: check for negative count for parse failure checking

2018-05-30 Thread Al Stone
On 05/30/2018 12:24 PM, Colin Ian King wrote: > On 30/05/18 18:59, Al Stone wrote: >> On 05/30/2018 11:14 AM, Colin King wrote: >>> From: Colin Ian King >>> >>> The function acpi_table_parse_enties_array can potentially return a >>> negative value if parsing fails. Currently the check on the

Re: [PATCH][next] mailbox: PCC: check for negative count for parse failure checking

2018-05-30 Thread Al Stone
On 05/30/2018 12:24 PM, Colin Ian King wrote: > On 30/05/18 18:59, Al Stone wrote: >> On 05/30/2018 11:14 AM, Colin King wrote: >>> From: Colin Ian King >>> >>> The function acpi_table_parse_enties_array can potentially return a >>> negative value if parsing fails. Currently the check on the

Re: [PATCH][next] mailbox: PCC: check for negative count for parse failure checking

2018-05-30 Thread Colin Ian King
On 30/05/18 18:59, Al Stone wrote: > On 05/30/2018 11:14 AM, Colin King wrote: >> From: Colin Ian King >> >> The function acpi_table_parse_enties_array can potentially return a >> negative value if parsing fails. Currently the check on the return >> is not checking for errors, so fix this by

Re: [PATCH][next] mailbox: PCC: check for negative count for parse failure checking

2018-05-30 Thread Colin Ian King
On 30/05/18 18:59, Al Stone wrote: > On 05/30/2018 11:14 AM, Colin King wrote: >> From: Colin Ian King >> >> The function acpi_table_parse_enties_array can potentially return a >> negative value if parsing fails. Currently the check on the return >> is not checking for errors, so fix this by

Re: [PATCH][next] mailbox: PCC: check for negative count for parse failure checking

2018-05-30 Thread Al Stone
On 05/30/2018 11:14 AM, Colin King wrote: > From: Colin Ian King > > The function acpi_table_parse_enties_array can potentially return a > negative value if parsing fails. Currently the check on the return > is not checking for errors, so fix this by adding a -ve check too. > > Detected by

Re: [PATCH][next] mailbox: PCC: check for negative count for parse failure checking

2018-05-30 Thread Al Stone
On 05/30/2018 11:14 AM, Colin King wrote: > From: Colin Ian King > > The function acpi_table_parse_enties_array can potentially return a > negative value if parsing fails. Currently the check on the return > is not checking for errors, so fix this by adding a -ve check too. > > Detected by

[PATCH][next] mailbox: PCC: check for negative count for parse failure checking

2018-05-30 Thread Colin King
From: Colin Ian King The function acpi_table_parse_enties_array can potentially return a negative value if parsing fails. Currently the check on the return is not checking for errors, so fix this by adding a -ve check too. Detected by CoverityScan, CID#1469477 ("Improper use of negative value")

[PATCH][next] mailbox: PCC: check for negative count for parse failure checking

2018-05-30 Thread Colin King
From: Colin Ian King The function acpi_table_parse_enties_array can potentially return a negative value if parsing fails. Currently the check on the return is not checking for errors, so fix this by adding a -ve check too. Detected by CoverityScan, CID#1469477 ("Improper use of negative value")