[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Zw40NajLjMa_AnY4@shikoro>
Date: Tue, 15 Oct 2024 11:21:57 +0200
From: Wolfram Sang <wsa+renesas@...g-engineering.com>
To: Krzysztof Kozlowski <krzk@...nel.org>
Cc: Troy Mitchell <troymitchell988@...il.com>, andi.shyti@...nel.org,
robh@...nel.org, krzk+dt@...nel.org, conor+dt@...nel.org,
linux-i2c@...r.kernel.org, devicetree@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH v1 2/2] i2c: spacemit: add support for SpacemiT K1 SoC
> > +static inline u32 spacemit_i2c_read_reg(struct spacemit_i2c_dev *i2c, int reg)
> > +{
> > + return readl(i2c->base + reg);
>
> So basically short and obvious code like this:
>
> readl(i2c->base + reg);
>
> you replace with:
>
> spacemit_i2c_read_reg(i2c, reg)
>
> how is this helpful?
I always have the same question when I see this. However, I don't blame
Troy. We have quite some occurances of this in the kernel, so I wouldn't
be surprised if people think this is a kernel-style-pattern :/
Download attachment "signature.asc" of type "application/pgp-signature" (834 bytes)
Powered by blists - more mailing lists