[PATCH 1/5] pwm: atmel-tcb: Harmonize resource allocation order
Uwe Kleine-König
u.kleine-koenig at pengutronix.de
Thu Jul 27 00:00:55 PDT 2023
Hello claudiu,
On Thu, Jul 27, 2023 at 09:00:28AM +0300, claudiu beznea wrote:
> On 19.07.2023 22:20, Uwe Kleine-König wrote:
> > + tcbpwm = devm_kzalloc(&pdev->dev, sizeof(*tcbpwm), GFP_KERNEL);
> > + if (tcbpwm == NULL)
>
> I know this was previously but maybe we can change it like this now:
> if (!tcbpwm)
>
> this is how is done in most of the memory alloc failure checks (AFAICT).
>
> > ...
> > - tcbpwm = devm_kzalloc(&pdev->dev, sizeof(*tcbpwm), GFP_KERNEL);
> > - if (tcbpwm == NULL) {
I don't care much. If and when I resend I will change to !tcbpwm.
Best regards
Uwe
--
Pengutronix e.K. | Uwe Kleine-König |
Industrial Linux Solutions | https://www.pengutronix.de/ |
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20230727/c0601623/attachment-0001.sig>
More information about the linux-arm-kernel
mailing list