From: Michał Nazarewicz on
On Mon, 19 Jul 2010 19:06:32 +0200, Alan Stern <stern(a)rowland.harvard.edu> wrote:
>> 1/3: http://lkml.org/lkml/2010/7/8/317

> Ah, yes. My personal taste would be to write fsg_string_serial_fill_n
> as an inline routine instead of as a macro, and not try to make it
> separate from fsg_string_serial_fill.

>> 2/3: http://lkml.org/lkml/2010/7/8/318

> I have only one objection to this patch: The new parameter's name
> should be "serial", not "serial_parm". (Compare it to all the other
> parameter names.)

Will change the two tomorrow.

> As for the discussion between you and David... I haven't tried to
> follow the details very carefully. I get the impression that the two
> of you are talking past each other instead of coming to grips with a
> genuine issue.

I'm not entirely sure of what the issue with the patches is really.
It merely adds a serial number to the gadgets using MSF and that's all.

In any event, I am sure we will come to an agreement at one point. :)

--
Best regards, _ _
| Humble Liege of Serenely Enlightened Majesty of o' \,=./ `o
| Computer Science, Michał "mina86" Nazarewicz (o o)
+----[mina86*mina86.com]---[mina86*jabber.org]----ooO--(_)--Ooo--
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo(a)vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
From: David Brownell on


--- On Mon, 7/19/10, Michał Nazarewicz <m.nazarewicz(a)samsung.com> wrote:

> I'm not entirely sure of what the issue with
> the patches is really. It merely adds a serial
> number to the gadgets using MSF and that's all.

Go back and read what I wrote then. The issue is
that THERE ALREADY IS SUCH A MECHANISM. We neither
need or want another way to do it. The answer is to
use the existing mechanism correctly.

Plus, you seem to be overlooking the basic need
(for userspace) to manage these IDs so they're
properly unique. Two gadgets should never end up
using the same serial number.

I tire of repeating these basic points...



--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo(a)vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
From: Alan Stern on
On Mon, 19 Jul 2010, [utf-8] Michał Nazarewicz wrote:

> On Mon, 19 Jul 2010 19:06:32 +0200, Alan Stern <stern(a)rowland.harvard.edu> wrote:
> >> 1/3: http://lkml.org/lkml/2010/7/8/317
>
> > Ah, yes. My personal taste would be to write fsg_string_serial_fill_n
> > as an inline routine instead of as a macro, and not try to make it
> > separate from fsg_string_serial_fill.
>
> >> 2/3: http://lkml.org/lkml/2010/7/8/318
>
> > I have only one objection to this patch: The new parameter's name
> > should be "serial", not "serial_parm". (Compare it to all the other
> > parameter names.)
>
> Will change the two tomorrow.

Come to think of it, there was one other issue. The serial number
parameter is important enough that it should be available even on
builds without CONFIG_USB_FILE_STORAGE_TEST (because for general use,
we must make it possible to set the serial number to a unique value for
every instance of the gadget). Moving the code around should be fairly
easy.

Alan Stern

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo(a)vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
From: Michał Nazarewicz on
On Mon, 19 Jul 2010 19:41:10 +0200, David Brownell <david-b(a)pacbell.net> wrote:
>> I'm not entirely sure of what the issue with
>> the patches is really. It merely adds a serial
>> number to the gadgets using MSF and that's all.
>
> Go back and read what I wrote then. The issue is
> that THERE ALREADY IS SUCH A MECHANISM. We neither
> need or want another way to do it. The answer is to
> use the existing mechanism correctly.

There is no existing mechanism. If the module does not set the
iSerialNumber field the iSerialNumber module parameter won't work
and I don't see any other way to set the string. If there is one,
please show it to me.

> Plus, you seem to be overlooking the basic need
> (for userspace) to manage these IDs so they're
> properly unique. Two gadgets should never end up
> using the same serial number.

I'm not overlooking that. I simply consider that a separate issue.
Driver should provide some kind of default (just like File Storage
Gadget) and the fact that user space should override it is another
matter in my opinion.

This is especially true, since the iSerialNumber module parameter
won't work without iSerialNumber set (which I pointed several
times).

--
Best regards, _ _
| Humble Liege of Serenely Enlightened Majesty of o' \,=./ `o
| Computer Science, Michał "mina86" Nazarewicz (o o)
+----[mina86*mina86.com]---[mina86*jabber.org]----ooO--(_)--Ooo--
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo(a)vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
From: Michał Nazarewicz on
> On Mon, 19 Jul 2010, [utf-8] Michal‚ Nazarewicz wrote:
>> 1/3: http://lkml.org/lkml/2010/7/8/317
>> Adds serial to mass storage gadget and g_multi introducing
>> fsg_string_serial_fill() macro used by abovementioned
>> gadgets and file storage gadget.

On Mon, 19 Jul 2010 19:06:32 +0200, Alan Stern <stern(a)rowland.harvard.edu> wrote:
> Ah, yes. My personal taste would be to write fsg_string_serial_fill_n
> as an inline routine instead of as a macro, and not try to make it
> separate from fsg_string_serial_fill.

Not sure what you meant by "make it separate from fsg_string_serial_fill".

--
Best regards, _ _
| Humble Liege of Serenely Enlightened Majesty of o' \,=./ `o
| Computer Science, Michał "mina86" Nazarewicz (o o)
+----[mina86*mina86.com]---[mina86*jabber.org]----ooO--(_)--Ooo--
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo(a)vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/