Thread (52 messages) 52 messages, 8 authors, 2022-08-04

Re: [PATCH v6 07/13] mfd: mt6370: Add MediaTek MT6370 support

From: Andy Shevchenko <hidden>
Date: 2022-07-25 08:43:47
Also in: dri-devel, linux-arm-kernel, linux-devicetree, linux-iio, linux-leds, linux-mediatek, linux-pm, linux-usb, lkml

On Mon, Jul 25, 2022 at 10:30 AM ChiaEn Wu [off-list ref] wrote:
On Mon, Jul 25, 2022 at 4:00 PM Andy Shevchenko
[off-list ref] wrote:
...
quoted
quoted
+#define MT6370_REG_DEV_INFO    0x100
+#define MT6370_REG_CHG_IRQ1    0x1C0
+#define MT6370_REG_CHG_MASK1   0x1E0
+
+#define MT6370_VENID_MASK      GENMASK(7, 4)
+
+#define MT6370_NUM_IRQREGS     16
+#define MT6370_USBC_I2CADDR    0x4E
quoted
+#define MT6370_REG_ADDRLEN     2
+#define MT6370_REG_MAXADDR     0x1FF
These two more logically to have near to other _REG_* definitions above.
Hi Andy,
Thanks for your review.
Do you mean that we should move '#define MT6370_USBC_I2CADDR' and
'#define MT6370_REG_MAXADDR' after the line '#define
MT6370_REG_CHG_MASK1'?
-------------------------------------------------------------------
#define MT6370_REG_DEV_INFO    0x100
#define MT6370_REG_CHG_IRQ1    0x1C0
#define MT6370_REG_CHG_MASK1   0x1E0
#define MT6370_USBC_I2CADDR    0x4E
#define MT6370_REG_MAXADDR     0x1FF

#define MT6370_VENID_MASK      GENMASK(7, 4)

#define MT6370_NUM_IRQREGS     16
#define MT6370_REG_ADDRLEN     2
-------------------------------------------------------------------
Like this?
You lost me. Namespace has a meaning, i.e. grouping items of a kind.
In your proposal I don't see that. If REG_MAXADDR and REG_ADDRLEN are
_not_ of the _REG_ kind as per above, why do they have this namespace
in the first place?

-- 
With Best Regards,
Andy Shevchenko
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help