Re: PATCH: fix iBFT firmware reading with newer kernels

2009-02-02 Thread Mike Christie
Mike Christie wrote: > Mike Christie wrote: >> Hans de Goede wrote: >>> Yes it does the same thing, is this from the open-iscsi VCS ? and where do >>> I >>> find that ? >>> >> Ok, I will merge up your code instead with the fixes in the thread. Thanks! >> > > Here is the rediffed patch. I used s

Re: PATCH: fix iBFT firmware reading with newer kernels

2009-01-29 Thread Hans de Goede
Mike Christie wrote: > Mike Christie wrote: >> Hans de Goede wrote: >>> Yes it does the same thing, is this from the open-iscsi VCS ? and where do >>> I >>> find that ? >>> >> Ok, I will merge up your code instead with the fixes in the thread. Thanks! >> > > Here is the rediffed patch. I used

Re: PATCH: fix iBFT firmware reading with newer kernels

2009-01-29 Thread Mike Christie
Mike Christie wrote: > Hans de Goede wrote: >> Yes it does the same thing, is this from the open-iscsi VCS ? and where do I >> find that ? >> > > Ok, I will merge up your code instead with the fixes in the thread. Thanks! > Here is the rediffed patch. I used strncat here: + strncat(dev_di

Re: PATCH: fix iBFT firmware reading with newer kernels

2009-01-29 Thread Mike Christie
Hans de Goede wrote: > Yes it does the same thing, is this from the open-iscsi VCS ? and where do I > find that ? > Ok, I will merge up your code instead with the fixes in the thread. Thanks! It is in our git tree. You can get it by doing: git clone git://git.kernel.org/pub/scm/linux/kernel/g

Re: PATCH: fix iBFT firmware reading with newer kernels

2009-01-29 Thread Mike Christie
Bart Van Assche wrote: > On Thu, Jan 29, 2009 at 12:34 AM, Mike Christie wrote: >> strncat(dev_dir, "/", FILENAMESZ); >> strncat(dev_dir, dent->d_name, FILENAMESZ); > > I assume the third argument should have been FILENAMESZ - strlen(dev_dir) ? >

Re: PATCH: fix iBFT firmware reading with newer kernels

2009-01-29 Thread Hans de Goede
Ulrich Windl wrote: > On 28 Jan 2009 at 17:34, Mike Christie wrote: > >> strncat(dev_dir, dent->d_name, FILENAMESZ); > > Hi, > > once again: The third argument of strncpy() counts the bytes to be added, not > the > bytes that are already there, so the code may not do

Re: PATCH: fix iBFT firmware reading with newer kernels

2009-01-29 Thread Hans de Goede
Bart Van Assche wrote: > On Thu, Jan 29, 2009 at 12:34 AM, Mike Christie wrote: >> strncat(dev_dir, "/", FILENAMESZ); >> strncat(dev_dir, dent->d_name, FILENAMESZ); > > I assume the third argument should have been FILENAMESZ - strlen(dev_dir) ? >

Re: PATCH: fix iBFT firmware reading with newer kernels

2009-01-29 Thread Hans de Goede
Ulrich Windl wrote: > On 28 Jan 2009 at 22:49, Hans de Goede wrote: > >> Hi, >> >> While testing I noticed that "iscsiadmin -m fw" does not work properly on >> newer >> (rawhide atleast) kernels, the attached patch (already applied to the Fedora >> devel packages) fixes this. > > Hi! > > I

Re: PATCH: fix iBFT firmware reading with newer kernels

2009-01-29 Thread Hans de Goede
Mike Christie wrote: > Hans de Goede wrote: >> Hi, >> >> While testing I noticed that "iscsiadmin -m fw" does not work properly on >> newer >> (rawhide atleast) kernels, the attached patch (already applied to the Fedora >> devel packages) fixes this. >> > p.s. > > If it is the same I will

Re: PATCH: fix iBFT firmware reading with newer kernels

2009-01-29 Thread Hans de Goede
Mike Christie wrote: > Hans de Goede wrote: >> Hi, >> >> While testing I noticed that "iscsiadmin -m fw" does not work properly on >> newer >> (rawhide atleast) kernels, the attached patch (already applied to the Fedora >> devel packages) fixes this. >> > > Did you port this from another fil

Re: PATCH: fix iBFT firmware reading with newer kernels

2009-01-29 Thread Ulrich Windl
On 28 Jan 2009 at 17:34, Mike Christie wrote: > strncat(dev_dir, dent->d_name, FILENAMESZ); Hi, once again: The third argument of strncpy() counts the bytes to be added, not the bytes that are already there, so the code may not do what some of you seem to expect! The

Re: PATCH: fix iBFT firmware reading with newer kernels

2009-01-29 Thread Bart Van Assche
On Thu, Jan 29, 2009 at 12:34 AM, Mike Christie wrote: > strncat(dev_dir, "/", FILENAMESZ); > strncat(dev_dir, dent->d_name, FILENAMESZ); I assume the third argument should have been FILENAMESZ - strlen(dev_dir) ? Bart. --~--~-~--~~--

Re: PATCH: fix iBFT firmware reading with newer kernels

2009-01-29 Thread Ulrich Windl
On 28 Jan 2009 at 22:49, Hans de Goede wrote: > Hi, > > While testing I noticed that "iscsiadmin -m fw" does not work properly on > newer > (rawhide atleast) kernels, the attached patch (already applied to the Fedora > devel packages) fixes this. Hi! I have almost no ideas on the implementa

Re: PATCH: fix iBFT firmware reading with newer kernels

2009-01-28 Thread Mike Christie
Hans de Goede wrote: > Hi, > > While testing I noticed that "iscsiadmin -m fw" does not work properly on > newer > (rawhide atleast) kernels, the attached patch (already applied to the Fedora > devel packages) fixes this. > Did you port this from another file/version? Not sure what I was th