lkml.org 
[lkml]   [2020]   [Nov]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v5 5/6] fpga: m10bmc-sec: add max10 secure update functions
From
Date

On 11/17/20 4:10 PM, Russ Weight wrote:
>
> On 11/15/20 6:17 AM, Tom Rix wrote:
>> On 11/13/20 4:55 PM, Russ Weight wrote:
>>> Extend the MAX10 BMC Secure Update driver to include
>>>
>>> +
>>> + status = rsu_stat(doorbell);
>>> + if (status == RSU_STAT_WEAROUT) {
>>> + dev_warn(sec->dev, "Excessive flash update count detected\n");
>> If wear out is going to flood logs, move this to a warn once.
> There is no danger of flooding. The WEAROUT error will only be seen after 1000
> flash updates have occurred - an unlikely condition. It will also only occur
> once on an update, and only if they attempt to flash within 60 seconds of
> power-on or within 60 seconds of a previous flash.
>> Maybe make rsu_stat a function.
> Is there a reason to prefer a function in this case? Or should I change
> rsu_stat() to RSU_STAT() to make it more clear that it is a macro?

i was thinking a function could manage the warning messages.

If it will not flood, it is ok as-is.

Tom

\
 
 \ /
  Last update: 2020-11-18 16:59    [W:0.034 / U:1.480 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site