lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <0182216b-5495-bcf7-bb0e-869133b24830@arm.com>
Date:   Thu, 20 Jun 2019 16:23:51 +0100
From:   Suzuki K Poulose <suzuki.poulose@....com>
To:     saiprakash.ranjan@...eaurora.org, mathieu.poirier@...aro.org,
        leo.yan@...aro.org, alexander.shishkin@...ux.intel.com,
        david.brown@...aro.org, mark.rutland@....com
Cc:     rnayak@...eaurora.org, vivek.gautam@...eaurora.org,
        sibis@...eaurora.org, linux-arm-kernel@...ts.infradead.org,
        linux-kernel@...r.kernel.org, linux-arm-msm@...r.kernel.org
Subject: Re: [PATCH 2/2] coresight: Abort probe for missing CPU phandle



On 20/06/2019 15:55, Sai Prakash Ranjan wrote:
> On 6/20/2019 7:28 PM, Suzuki K Poulose wrote:
>>
>>
>> On 20/06/2019 14:45, Sai Prakash Ranjan wrote:
>>> Currently the coresight etm and cpu-debug drivers
>>> assume the affinity to CPU0 returned by coresight
>>> platform and continue the probe in case of missing
>>> CPU phandle. This is not true and leads to crash
>>> in some cases, so abort the probe in case of missing
>>> CPU phandle.
>>>
>>> Signed-off-by: Sai Prakash Ranjan <saiprakash.ranjan@...eaurora.org>
>>> ---
>>>    drivers/hwtracing/coresight/coresight-cpu-debug.c | 3 +++
>>>    drivers/hwtracing/coresight/coresight-etm3x.c     | 3 +++
>>>    drivers/hwtracing/coresight/coresight-etm4x.c     | 3 +++
>>>    3 files changed, 9 insertions(+)
>>>
>>> diff --git a/drivers/hwtracing/coresight/coresight-cpu-debug.c
>>> b/drivers/hwtracing/coresight/coresight-cpu-debug.c
>>> index 07a1367c733f..43f32fa71ff9 100644
>>> --- a/drivers/hwtracing/coresight/coresight-cpu-debug.c
>>> +++ b/drivers/hwtracing/coresight/coresight-cpu-debug.c
>>> @@ -579,6 +579,9 @@ static int debug_probe(struct amba_device *adev,
>>> const struct amba_id *id)
>>>            return -ENOMEM;
>>>        drvdata->cpu = coresight_get_cpu(dev);
>>> +    if (drvdata->cpu == -ENODEV)
>>> +        return -ENODEV;
>>
>> if (drvdata->cpu < 0)
>>       return drvdata->cpu;
>>
>> Same everywhere below ?
>>
>> Also, I would like to hear Mathieu's thoughts on this change. If he's OK
>> with it:
>>
>> Reviewed-by: Suzuki K Poulose <suzuki.poulose@....com> with the change
>> above.
>>
>>
> 
> Thanks, I will make the change and repost.

Please wait for Mathieu's thoughts on it. And in general I would wait
for feedback from the people in a version, before posting another one,
to reduce the number of respins.

Cheers
Suzuki

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ