mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] Fix a const assignment in moxa_load_fw()
@ 2008-07-08 15:44 David Howells
  2008-07-08 16:10 ` Alan Cox
  0 siblings, 1 reply; 6+ messages in thread
From: David Howells @ 2008-07-08 15:44 UTC (permalink / raw)
  To: jirislaby, akpm; +Cc: dhowells, linux-kernel

Fix an assignment of a const pointer to a non-const pointer in moxa_load_fw().

This was introduced by patch 037182346f0991683cc7320a257c3f6089432cee.

Signed-off-by: David Howells <dhowells@redhat.com>
---

 drivers/char/moxa.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)


diff --git a/drivers/char/moxa.c b/drivers/char/moxa.c
index d57d3a6..e21346d 100644
--- a/drivers/char/moxa.c
+++ b/drivers/char/moxa.c
@@ -721,7 +721,7 @@ static int moxa_load_code(struct moxa_board_conf *brd, const void *ptr,
 
 static int moxa_load_fw(struct moxa_board_conf *brd, const struct firmware *fw)
 {
-	void *ptr = fw->data;
+	const void *ptr = fw->data;
 	char rsn[64];
 	u16 lens[5];
 	size_t len;
@@ -734,7 +734,7 @@ static int moxa_load_fw(struct moxa_board_conf *brd, const struct firmware *fw)
 		u8 model;	/* C218T=1, C320T=2, CP204=3 */
 		u8 reserved2[8];
 		__le16 len[5];
-	} *hdr = ptr;
+	} const *hdr = ptr;
 
 	BUILD_BUG_ON(ARRAY_SIZE(hdr->len) != ARRAY_SIZE(lens));
 


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

* Re: [PATCH] Fix a const assignment in moxa_load_fw()
  2008-07-08 15:44 [PATCH] Fix a const assignment in moxa_load_fw() David Howells
@ 2008-07-08 16:10 ` Alan Cox
  2008-07-11 19:20   ` Andrew Morton
  2008-07-11 22:48   ` David Howells
  0 siblings, 2 replies; 6+ messages in thread
From: Alan Cox @ 2008-07-08 16:10 UTC (permalink / raw)
  To: David Howells; +Cc: jirislaby, akpm, dhowells, linux-kernel

On Tue, 08 Jul 2008 16:44:16 +0100
David Howells <dhowells@redhat.com> wrote:

> Fix an assignment of a const pointer to a non-const pointer in moxa_load_fw().
> 
> This was introduced by patch 037182346f0991683cc7320a257c3f6089432cee.
> 
> Signed-off-by: David Howells <dhowells@redhat.com>

Acked-by: Alan Cox <alan@redhat.com>

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

* Re: [PATCH] Fix a const assignment in moxa_load_fw()
  2008-07-08 16:10 ` Alan Cox
@ 2008-07-11 19:20   ` Andrew Morton
  2008-07-11 23:26     ` Stephen Rothwell
  2008-07-11 22:48   ` David Howells
  1 sibling, 1 reply; 6+ messages in thread
From: Andrew Morton @ 2008-07-11 19:20 UTC (permalink / raw)
  To: Alan Cox; +Cc: David Howells, jirislaby, linux-kernel

On Tue, 8 Jul 2008 17:10:29 +0100 Alan Cox <alan@lxorguk.ukuu.org.uk> wrote:

> On Tue, 08 Jul 2008 16:44:16 +0100
> David Howells <dhowells@redhat.com> wrote:
> 
> > Fix an assignment of a const pointer to a non-const pointer in moxa_load_fw().
> > 
> > This was introduced by patch 037182346f0991683cc7320a257c3f6089432cee.
> > 
> > Signed-off-by: David Howells <dhowells@redhat.com>
> 
> Acked-by: Alan Cox <alan@redhat.com>

Appears to already be fixed in linux-next, perhaps by this:

commit b30a6a47716ba1a5112b44f0a3962daff961935e
Author: Alan Cox <alan@redhat.com>
Date:   Fri Jul 4 19:18:14 2008 +1000

    83-tty-moxa-warning
    
    Signed-off-by: Alan Cox <alan@redhat.com>

which, err, isn't in today's linux-next because the whole tty tree got
accidentally dropped.  Not that this was a tty patch.

Hopefully the patches in this tree will get title and changelog repairs
before they go much further.  I suspect a lot of this damage was due to
incompatibility between Alan's patch-file format and the expectations of
Stephen's scripts.

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

* Re: [PATCH] Fix a const assignment in moxa_load_fw()
  2008-07-08 16:10 ` Alan Cox
  2008-07-11 19:20   ` Andrew Morton
@ 2008-07-11 22:48   ` David Howells
  2008-07-11 22:58     ` Andrew Morton
  1 sibling, 1 reply; 6+ messages in thread
From: David Howells @ 2008-07-11 22:48 UTC (permalink / raw)
  To: Andrew Morton; +Cc: dhowells, Alan Cox, jirislaby, linux-kernel

Andrew Morton <akpm@linux-foundation.org> wrote:

> Appears to already be fixed in linux-next, perhaps by this:

Some of the maintainers have already pushed through the patches I've sent to
you and them.

David

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

* Re: [PATCH] Fix a const assignment in moxa_load_fw()
  2008-07-11 22:48   ` David Howells
@ 2008-07-11 22:58     ` Andrew Morton
  0 siblings, 0 replies; 6+ messages in thread
From: Andrew Morton @ 2008-07-11 22:58 UTC (permalink / raw)
  To: David Howells; +Cc: Alan Cox, jirislaby, linux-kernel

On Fri, 11 Jul 2008 23:48:21 +0100 David Howells <dhowells@redhat.com> wrote:

> Andrew Morton <akpm@linux-foundation.org> wrote:
> 
> > Appears to already be fixed in linux-next, perhaps by this:
> 
> Some of the maintainers have already pushed through the patches I've sent to
> you and them.
> 

No, that was a week-old tree - the warning was fixed independently.  As
they often are - everyone gets to watch them fly past so lots of people
are motivated to fix them, and are able to test their fixes.

linux-next would be a better tree against which to do this sort of
thing.  Doing that would avoid this wasted effort, plus linux-next has
lots of nice new warnings to keep us occupied.

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

* Re: [PATCH] Fix a const assignment in moxa_load_fw()
  2008-07-11 19:20   ` Andrew Morton
@ 2008-07-11 23:26     ` Stephen Rothwell
  0 siblings, 0 replies; 6+ messages in thread
From: Stephen Rothwell @ 2008-07-11 23:26 UTC (permalink / raw)
  To: Andrew Morton; +Cc: Alan Cox, David Howells, jirislaby, linux-kernel

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

Hi Andrew,

On Fri, 11 Jul 2008 12:20:56 -0700 Andrew Morton <akpm@linux-foundation.org> wrote:
>
> Appears to already be fixed in linux-next, perhaps by this:
> 
> commit b30a6a47716ba1a5112b44f0a3962daff961935e
> Author: Alan Cox <alan@redhat.com>
> Date:   Fri Jul 4 19:18:14 2008 +1000
> 
>     83-tty-moxa-warning

Which became 88-tty-moxa-warning and was dropped (the individual patch)
from next-20080711 because it didn't apply.

>     
>     Signed-off-by: Alan Cox <alan@redhat.com>
> 
> which, err, isn't in today's linux-next because the whole tty tree got
> accidentally dropped.  Not that this was a tty patch.

All except two patches from the ttydev tree are in
"today's" (next-20080711) linux-next tree.  (The tag is better than
saying "today" since I am in a different time zone to most of you :-))
The whole tree was dropped a few days ago but came back.

> Hopefully the patches in this tree will get title and changelog repairs
> before they go much further.  I suspect a lot of this damage was due to
> incompatibility between Alan's patch-file format and the expectations of
> Stephen's scripts.

Yeah, Alan and I need to have a conversation about that ...

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

[-- Attachment #2: Type: application/pgp-signature, Size: 197 bytes --]

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

end of thread, other threads:[~2008-07-11 23:27 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-07-08 15:44 [PATCH] Fix a const assignment in moxa_load_fw() David Howells
2008-07-08 16:10 ` Alan Cox
2008-07-11 19:20   ` Andrew Morton
2008-07-11 23:26     ` Stephen Rothwell
2008-07-11 22:48   ` David Howells
2008-07-11 22:58     ` Andrew Morton

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome