linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] twl4030: It would be better not to use the 0b-prefix.
@ 2012-08-17  7:49 Il Han
  2012-08-17  9:30 ` NeilBrown
  0 siblings, 1 reply; 3+ messages in thread
From: Il Han @ 2012-08-17  7:49 UTC (permalink / raw)
  To: Anton Vorontsov, David Woodhouse, Neil Brown; +Cc: linux-kernel, Il Han

It would be better not to use the 0b-prefix for earlier versions of gcc-4.3.
Please, Modify it.

Signed-off-by: Il Han <corone.il.han@gmail.com>
---
 drivers/power/twl4030_charger.c | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)

diff --git a/drivers/power/twl4030_charger.c b/drivers/power/twl4030_charger.c
index 15f4d5d..8d6bc68 100644
--- a/drivers/power/twl4030_charger.c
+++ b/drivers/power/twl4030_charger.c
@@ -41,16 +41,16 @@
 #define TWL4030_STS_VBUS	BIT(7)
 #define TWL4030_STS_USB_ID	BIT(2)
 #define TWL4030_BBCHEN		BIT(4)
-#define TWL4030_BBSEL_MASK	0b1100
-#define TWL4030_BBSEL_2V5	0b0000
-#define TWL4030_BBSEL_3V0	0b0100
-#define TWL4030_BBSEL_3V1	0b1000
-#define TWL4030_BBSEL_3V2	0b1100
-#define TWL4030_BBISEL_MASK	0b11
-#define TWL4030_BBISEL_25uA	0b00
-#define TWL4030_BBISEL_150uA	0b01
-#define TWL4030_BBISEL_500uA	0b10
-#define TWL4030_BBISEL_1000uA	0b11
+#define TWL4030_BBSEL_MASK	0x0c
+#define TWL4030_BBSEL_2V5	0x00
+#define TWL4030_BBSEL_3V0	0x04
+#define TWL4030_BBSEL_3V1	0x08
+#define TWL4030_BBSEL_3V2	0x0c
+#define TWL4030_BBISEL_MASK	0x03
+#define TWL4030_BBISEL_25uA	0x00
+#define TWL4030_BBISEL_150uA	0x01
+#define TWL4030_BBISEL_500uA	0x02
+#define TWL4030_BBISEL_1000uA	0x03
 
 /* BCI interrupts */
 #define TWL4030_WOVF		BIT(0) /* Watchdog overflow */
-- 
1.7.11.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] twl4030: It would be better not to use the 0b-prefix.
  2012-08-17  7:49 [PATCH] twl4030: It would be better not to use the 0b-prefix Il Han
@ 2012-08-17  9:30 ` NeilBrown
  2012-08-23  2:41   ` Anton Vorontsov
  0 siblings, 1 reply; 3+ messages in thread
From: NeilBrown @ 2012-08-17  9:30 UTC (permalink / raw)
  To: Il Han; +Cc: Anton Vorontsov, David Woodhouse, linux-kernel, Chris Ball, werner

[-- Attachment #1: Type: text/plain, Size: 1654 bytes --]

On Fri, 17 Aug 2012 16:49:43 +0900 Il Han <corone.il.han@gmail.com> wrote:

> It would be better not to use the 0b-prefix for earlier versions of gcc-4.3.
> Please, Modify it.
> 
> Signed-off-by: Il Han <corone.il.han@gmail.com>
> ---
>  drivers/power/twl4030_charger.c | 20 ++++++++++----------
>  1 file changed, 10 insertions(+), 10 deletions(-)
> 
> diff --git a/drivers/power/twl4030_charger.c b/drivers/power/twl4030_charger.c
> index 15f4d5d..8d6bc68 100644
> --- a/drivers/power/twl4030_charger.c
> +++ b/drivers/power/twl4030_charger.c
> @@ -41,16 +41,16 @@
>  #define TWL4030_STS_VBUS	BIT(7)
>  #define TWL4030_STS_USB_ID	BIT(2)
>  #define TWL4030_BBCHEN		BIT(4)
> -#define TWL4030_BBSEL_MASK	0b1100
> -#define TWL4030_BBSEL_2V5	0b0000
> -#define TWL4030_BBSEL_3V0	0b0100
> -#define TWL4030_BBSEL_3V1	0b1000
> -#define TWL4030_BBSEL_3V2	0b1100
> -#define TWL4030_BBISEL_MASK	0b11
> -#define TWL4030_BBISEL_25uA	0b00
> -#define TWL4030_BBISEL_150uA	0b01
> -#define TWL4030_BBISEL_500uA	0b10
> -#define TWL4030_BBISEL_1000uA	0b11
> +#define TWL4030_BBSEL_MASK	0x0c
> +#define TWL4030_BBSEL_2V5	0x00
> +#define TWL4030_BBSEL_3V0	0x04
> +#define TWL4030_BBSEL_3V1	0x08
> +#define TWL4030_BBSEL_3V2	0x0c
> +#define TWL4030_BBISEL_MASK	0x03
> +#define TWL4030_BBISEL_25uA	0x00
> +#define TWL4030_BBISEL_150uA	0x01
> +#define TWL4030_BBISEL_500uA	0x02
> +#define TWL4030_BBISEL_1000uA	0x03
>  
>  /* BCI interrupts */
>  #define TWL4030_WOVF		BIT(0) /* Watchdog overflow */

Thanks.  I'd been meaning to send that patch, but life got in the way
recently.

Acked-by: NeilBrown <neilb@suse.de>

NeilBrown

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 828 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] twl4030: It would be better not to use the 0b-prefix.
  2012-08-17  9:30 ` NeilBrown
@ 2012-08-23  2:41   ` Anton Vorontsov
  0 siblings, 0 replies; 3+ messages in thread
From: Anton Vorontsov @ 2012-08-23  2:41 UTC (permalink / raw)
  To: NeilBrown; +Cc: Il Han, David Woodhouse, linux-kernel, Chris Ball, werner

On Fri, Aug 17, 2012 at 07:30:46PM +1000, NeilBrown wrote:
[...]
> > -#define TWL4030_BBISEL_1000uA	0b11
> > +#define TWL4030_BBSEL_MASK	0x0c
[...]
> Thanks.  I'd been meaning to send that patch, but life got in the way
> recently.
> 
> Acked-by: NeilBrown <neilb@suse.de>

Thanks! Applied.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-08-23  2:44 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-08-17  7:49 [PATCH] twl4030: It would be better not to use the 0b-prefix Il Han
2012-08-17  9:30 ` NeilBrown
2012-08-23  2:41   ` Anton Vorontsov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).