* [PATCH 1/2] extcon: max8997: use dev_err() instead of pr_err()
@ 2013-03-19 2:02 Jingoo Han
2013-03-19 2:03 ` [PATCH 2/2] extcon: max8997: add missing const Jingoo Han
0 siblings, 1 reply; 4+ messages in thread
From: Jingoo Han @ 2013-03-19 2:02 UTC (permalink / raw)
To: 'MyungJoo Ham'
Cc: 'Chanwoo Choi', linux-kernel, 'Jingoo Han'
dev_err() is more preferred than pr_err().
Signed-off-by: Jingoo Han <jg1.han@samsung.com>
---
drivers/extcon/extcon-max8997.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/extcon/extcon-max8997.c b/drivers/extcon/extcon-max8997.c
index 69641bc..20772ad 100644
--- a/drivers/extcon/extcon-max8997.c
+++ b/drivers/extcon/extcon-max8997.c
@@ -646,7 +646,7 @@ static void max8997_muic_detect_cable_wq(struct work_struct *work)
ret = max8997_muic_detect_dev(info);
if (ret < 0)
- pr_err("failed to detect cable type\n");
+ dev_err(info->dev, "failed to detect cable type\n");
}
static int max8997_muic_probe(struct platform_device *pdev)
--
1.7.2.5
^ permalink raw reply [flat|nested] 4+ messages in thread* [PATCH 2/2] extcon: max8997: add missing const
2013-03-19 2:02 [PATCH 1/2] extcon: max8997: use dev_err() instead of pr_err() Jingoo Han
@ 2013-03-19 2:03 ` Jingoo Han
2013-03-19 3:33 ` Sachin Kamat
0 siblings, 1 reply; 4+ messages in thread
From: Jingoo Han @ 2013-03-19 2:03 UTC (permalink / raw)
To: 'MyungJoo Ham'
Cc: 'Chanwoo Choi', linux-kernel, 'Jingoo Han'
Fixed the checkpatch warning as below:
WARNING: static const char * array should probably be static const char * const
#163: FILE: drivers/extcon/extcon-max8997.c:163:
+static const char *max8997_extcon_cable[] = {
Signed-off-by: Jingoo Han <jg1.han@samsung.com>
---
drivers/extcon/extcon-max8997.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/extcon/extcon-max8997.c b/drivers/extcon/extcon-max8997.c
index 20772ad..6e8724f 100644
--- a/drivers/extcon/extcon-max8997.c
+++ b/drivers/extcon/extcon-max8997.c
@@ -160,7 +160,7 @@ enum {
_EXTCON_CABLE_NUM,
};
-static const char *max8997_extcon_cable[] = {
+static const char const *max8997_extcon_cable[] = {
[EXTCON_CABLE_USB] = "USB",
[EXTCON_CABLE_USB_HOST] = "USB-Host",
[EXTCON_CABLE_TA] = "TA",
--
1.7.2.5
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: [PATCH 2/2] extcon: max8997: add missing const
2013-03-19 2:03 ` [PATCH 2/2] extcon: max8997: add missing const Jingoo Han
@ 2013-03-19 3:33 ` Sachin Kamat
2013-03-19 3:37 ` Jingoo Han
0 siblings, 1 reply; 4+ messages in thread
From: Sachin Kamat @ 2013-03-19 3:33 UTC (permalink / raw)
To: Jingoo Han; +Cc: MyungJoo Ham, Chanwoo Choi, linux-kernel
On 19 March 2013 07:33, Jingoo Han <jg1.han@samsung.com> wrote:
> Fixed the checkpatch warning as below:
>
> WARNING: static const char * array should probably be static const char * const
> #163: FILE: drivers/extcon/extcon-max8997.c:163:
> +static const char *max8997_extcon_cable[] = {
>
> Signed-off-by: Jingoo Han <jg1.han@samsung.com>
> ---
> drivers/extcon/extcon-max8997.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/extcon/extcon-max8997.c b/drivers/extcon/extcon-max8997.c
> index 20772ad..6e8724f 100644
> --- a/drivers/extcon/extcon-max8997.c
> +++ b/drivers/extcon/extcon-max8997.c
> @@ -160,7 +160,7 @@ enum {
> _EXTCON_CABLE_NUM,
> };
>
> -static const char *max8997_extcon_cable[] = {
> +static const char const *max8997_extcon_cable[] = {
Shouldn't this be "static const char * const max8997_extcon_cable[]"
as suggested by checkpatch (as mentioned in your commit log)?
--
With warm regards,
Sachin
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: [PATCH 2/2] extcon: max8997: add missing const
2013-03-19 3:33 ` Sachin Kamat
@ 2013-03-19 3:37 ` Jingoo Han
0 siblings, 0 replies; 4+ messages in thread
From: Jingoo Han @ 2013-03-19 3:37 UTC (permalink / raw)
To: 'Sachin Kamat'
Cc: 'MyungJoo Ham', 'Chanwoo Choi',
linux-kernel, 'Jingoo Han'
> -----Original Message-----
> From: Sachin Kamat [mailto:sachin.kamat@linaro.org]
> Sent: Tuesday, March 19, 2013 12:33 PM
> To: Jingoo Han
> Cc: MyungJoo Ham; Chanwoo Choi; linux-kernel@vger.kernel.org
> Subject: Re: [PATCH 2/2] extcon: max8997: add missing const
>
> On 19 March 2013 07:33, Jingoo Han <jg1.han@samsung.com> wrote:
> > Fixed the checkpatch warning as below:
> >
> > WARNING: static const char * array should probably be static const char * const
> > #163: FILE: drivers/extcon/extcon-max8997.c:163:
> > +static const char *max8997_extcon_cable[] = {
> >
> > Signed-off-by: Jingoo Han <jg1.han@samsung.com>
> > ---
> > drivers/extcon/extcon-max8997.c | 2 +-
> > 1 files changed, 1 insertions(+), 1 deletions(-)
> >
> > diff --git a/drivers/extcon/extcon-max8997.c b/drivers/extcon/extcon-max8997.c
> > index 20772ad..6e8724f 100644
> > --- a/drivers/extcon/extcon-max8997.c
> > +++ b/drivers/extcon/extcon-max8997.c
> > @@ -160,7 +160,7 @@ enum {
> > _EXTCON_CABLE_NUM,
> > };
> >
> > -static const char *max8997_extcon_cable[] = {
> > +static const char const *max8997_extcon_cable[] = {
>
> Shouldn't this be "static const char * const max8997_extcon_cable[]"
> as suggested by checkpatch (as mentioned in your commit log)?
Hi Sachin Kamat,
Although the checkpatch warning is already fixed, I will send v2 patch
for clarity.
Thank you for your comment.
Best regards,
Jingoo Han
>
>
> --
> With warm regards,
> Sachin
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2013-03-19 3:37 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-03-19 2:02 [PATCH 1/2] extcon: max8997: use dev_err() instead of pr_err() Jingoo Han
2013-03-19 2:03 ` [PATCH 2/2] extcon: max8997: add missing const Jingoo Han
2013-03-19 3:33 ` Sachin Kamat
2013-03-19 3:37 ` Jingoo Han
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®