From: Florian Fainelli <f.fainelli@gmail.com>
To: Guenter Roeck <linux@roeck-us.net>, madhuparnabhowmik10@gmail.com
Cc: wim@linux-watchdog.org, linux-watchdog@vger.kernel.org,
linux-kernel@vger.kernel.org, andrianov@ispras.ru,
ldv-project@linuxtesting.org
Subject: Re: [PATCH] drivers: watchdog: rdc321x_wdt: Fix race condition bugs
Date: Fri, 7 Aug 2020 13:09:02 -0700 [thread overview]
Message-ID: <1b9db5ad-0edf-091b-a04e-a8f3a6ac08e2@gmail.com> (raw)
In-Reply-To: <bc8c5d7d-91a4-e955-854f-eef88812ac1a@roeck-us.net>
On 8/7/2020 12:08 PM, Guenter Roeck wrote:
> On 8/7/20 11:08 AM, Florian Fainelli wrote:
>>
>>
>> On 8/7/2020 9:21 AM, Guenter Roeck wrote:
>>> On Fri, Aug 07, 2020 at 04:59:02PM +0530, madhuparnabhowmik10@gmail.com wrote:
>>>> From: Madhuparna Bhowmik <madhuparnabhowmik10@gmail.com>
>>>>
>>>> In rdc321x_wdt_probe(), rdc321x_wdt_device.queue is initialized
>>>> after misc_register(), hence if ioctl is called before its
>>>> initialization which can call rdc321x_wdt_start() function,
>>>> it will see an uninitialized value of rdc321x_wdt_device.queue,
>>>> hence initialize it before misc_register().
>>>> Also, rdc321x_wdt_device.default_ticks is accessed in reset()
>>>> function called from write callback, thus initialize it before
>>>> misc_register().
>>>>
>>>> Found by Linux Driver Verification project (linuxtesting.org).
>>>>
>>>> Signed-off-by: Madhuparna Bhowmik <madhuparnabhowmik10@gmail.com>
>>>
>>> Reviewed-by: Guenter Roeck <linux@roeck-us.net>
>>>
>>> Having said that ... this is yet another potentially obsolete driver.
>>> You are really wasting your (and, fwiw, my) time.
>>>
>>> Florian, any thoughts if support for this chip can/should be deprecated
>>> or even removed ?
>>
>> I am still using my rdc321x-based SoC, so no, this is not obsolete as
>> far as I am concerned, time permitting, modernizing the driver is on my
>> TODO after checking/fixing the Ethernet driver first.
>>
>
> Do you have a manual ? I'd give it a try if you can test it - conversion
> should be simple enough (I have a coccinelle script which partially
> automates it), but this chip seems to have a fast timeout, and the
> comments in the code ("set the timeout to 81.92 us") seem to be quite
> obviously wrong.
Yes, there is a public manual for that SoC, search for RDC R8610 and the
first link you find should be a 276 page long manual for the SoC.
I probably won't be able to test anything until the middle of next week
though.
--
Florian
next prev parent reply other threads:[~2020-08-07 20:09 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-07 11:29 madhuparnabhowmik10
2020-08-07 16:21 ` Guenter Roeck
2020-08-07 18:08 ` Florian Fainelli
2020-08-07 18:19 ` Guenter Roeck
2020-08-07 19:08 ` Guenter Roeck
2020-08-07 20:09 ` Florian Fainelli [this message]
2020-08-07 23:23 ` Guenter Roeck
2020-08-08 0:41 ` Florian Fainelli
2020-08-08 4:58 ` Guenter Roeck
2020-08-07 18:30 ` [ldv-project] " Evgeny Novikov
2020-08-07 19:00 ` Guenter Roeck
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1b9db5ad-0edf-091b-a04e-a8f3a6ac08e2@gmail.com \
--to=f.fainelli@gmail.com \
--cc=andrianov@ispras.ru \
--cc=ldv-project@linuxtesting.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-watchdog@vger.kernel.org \
--cc=linux@roeck-us.net \
--cc=madhuparnabhowmik10@gmail.com \
--cc=wim@linux-watchdog.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome