Re: [Fwd: [patch 11/15] ppp: handle misaligned accesses]

2005-08-11 Thread Philippe De Muyter
I wrote : > I just noticed something at the end of process_input_packet : > In the normal case, skb is given to the next stage and ap->rpkt is reset, > but in the error case, skb is kept, ap->rpkt is not reset, so we keep > the skb with skb->data aligned for one message and we put another one > int

Re: [Fwd: [patch 11/15] ppp: handle misaligned accesses]

2005-08-10 Thread Philippe De Muyter
Paul Mackerras wrote : > Philippe De Muyter writes: > > > Actually, that's probably the case I had, but my fix gets the ip adresses > > 4byte aligned in my case : I had verified the address of the saddr field, > > and I needed to shift the buffer by 3, not 1, to get it 4byte aligned. > > Please o

Re: [Fwd: [patch 11/15] ppp: handle misaligned accesses]

2005-08-09 Thread Paul Mackerras
Philippe De Muyter writes: > Actually, that's probably the case I had, but my fix gets the ip adresses > 4byte aligned in my case : I had verified the address of the saddr field, > and I needed to shift the buffer by 3, not 1, to get it 4byte aligned. Please outline the code flow that leads to th

Re: [Fwd: [patch 11/15] ppp: handle misaligned accesses]

2005-08-09 Thread Philippe De Muyter
Paul Mackerras wrote : > Philippe De Muyter writes: > > > > This patch seems a bit strange and/or incomplete. Are we trying to > > > get 2-byte alignment or 4-byte alignment of the payload? It seems > > > > Actually, we try to get a 4n+2 alignment for skb->data, to get the > > ip-addresses > >

Re: [Fwd: [patch 11/15] ppp: handle misaligned accesses]

2005-08-09 Thread Paul Mackerras
Philippe De Muyter writes: > > This patch seems a bit strange and/or incomplete. Are we trying to > > get 2-byte alignment or 4-byte alignment of the payload? It seems > > Actually, we try to get a 4n+2 alignment for skb->data, to get the > ip-addresses > field 4bytes aligned. > I think the on

Re: [Fwd: [patch 11/15] ppp: handle misaligned accesses]

2005-08-09 Thread Philippe De Muyter
Paul Mackerras wrote : > Jeff Garzik writes: > > > From: "Philippe De Muyter" <[EMAIL PROTECTED]> > > > > Avoid ppp-generated kernel crashes on machines where unaligned accesses are > > forbidden (ie: 68000-based CPUs) > > This patch seems a bit strange and/or incomplete. Are we trying to > get

Re: [Fwd: [patch 11/15] ppp: handle misaligned accesses]

2005-08-01 Thread Patrick McHardy
Paul Mackerras wrote: > Can we assume that dev_alloc_skb will give us a 4-byte aligned > skb->data? If we can then I suggest we change 3 to 1 in the skb_put > and memmove above, and get rid of the if (since its condition will > always be false). The usual kmalloc alignment rules hold for skb->hea

Re: [Fwd: [patch 11/15] ppp: handle misaligned accesses]

2005-08-01 Thread Paul Mackerras
Jeff Garzik writes: > From: "Philippe De Muyter" <[EMAIL PROTECTED]> > > Avoid ppp-generated kernel crashes on machines where unaligned accesses are > forbidden (ie: 68000-based CPUs) This patch seems a bit strange and/or incomplete. Are we trying to get 2-byte alignment or 4-byte alignment of

Re: [patch 11/15] ppp: handle misaligned accesses

2005-08-01 Thread Philippe De Muyter
Andrew Morton wrote : > Jeff Garzik <[EMAIL PROTECTED]> wrote: > > > > [EMAIL PROTECTED] wrote: > > > From: "Philippe De Muyter" <[EMAIL PROTECTED]> > > > > > > Avoid ppp-generated kernel crashes on machines where unaligned accesses > > > are > > > forbidden (ie: 68000-based CPUs) > > > > > > Si

Re: [patch 11/15] ppp: handle misaligned accesses

2005-07-30 Thread Andrew Morton
Jeff Garzik <[EMAIL PROTECTED]> wrote: > > [EMAIL PROTECTED] wrote: > > From: "Philippe De Muyter" <[EMAIL PROTECTED]> > > > > Avoid ppp-generated kernel crashes on machines where unaligned accesses are > > forbidden (ie: 68000-based CPUs) > > > > Signed-off-by: Philippe De Muyter <[EMAIL PROTECT

Re: [patch 11/15] ppp: handle misaligned accesses

2005-07-30 Thread Jeff Garzik
[EMAIL PROTECTED] wrote: From: "Philippe De Muyter" <[EMAIL PROTECTED]> Avoid ppp-generated kernel crashes on machines where unaligned accesses are forbidden (ie: 68000-based CPUs) Signed-off-by: Philippe De Muyter <[EMAIL PROTECTED]> Cc: "David S. Miller" <[EMAIL PROTECTED]> Signed-off-by: And