[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAKdAkRQT_Jk5yBeMZqh=M1JscVLFieZTQjLGOGxy8nHh8SnD3A@mail.gmail.com>
Date: Tue, 31 Jan 2023 15:52:55 -0800
From: Dmitry Torokhov <dmitry.torokhov@...il.com>
To: Arnd Bergmann <arnd@...nel.org>
Cc: Alexander Aring <alex.aring@...il.com>,
Stefan Schmidt <stefan@...enfreihafen.org>,
Arnd Bergmann <arnd@...db.de>,
Miquel Raynal <miquel.raynal@...tlin.com>,
Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
"David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>,
Paolo Abeni <pabeni@...hat.com>, linux-kernel@...r.kernel.org,
linux-wpan@...r.kernel.org, netdev@...r.kernel.org
Subject: Re: [PATCH] [v2] at86rf230: convert to gpio descriptors
Hi Arnd,
On Thu, Jan 26, 2023 at 8:32 AM Arnd Bergmann <arnd@...nel.org> wrote:
>
> /* Reset */
> - if (gpio_is_valid(rstn)) {
> + if (rstn) {
> udelay(1);
> - gpio_set_value_cansleep(rstn, 0);
> + gpiod_set_value_cansleep(rstn, 0);
> udelay(1);
> - gpio_set_value_cansleep(rstn, 1);
> + gpiod_set_value_cansleep(rstn, 1);
For gpiod conversions, if we are not willing to chase whether existing
DTSes specify polarities
properly and create workarounds in case they are wrong, we should use
gpiod_set_raw_value*()
(my preference would be to do the work and not use "raw" variants).
In this particular case, arch/arm/boot/dts/vf610-zii-dev-rev-c.dts
defines reset line as active low,
so you are leaving the device in reset state.
Please review your other conversion patches.
--
Dmitry
Powered by blists - more mailing lists