public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* declare MODULE_FIRMWARE in libsas
@ 2011-01-04  7:43 DuanZhenzhong
  2011-01-04 14:08 ` James Bottomley
  0 siblings, 1 reply; 9+ messages in thread
From: DuanZhenzhong @ 2011-01-04  7:43 UTC (permalink / raw)
  To: linux-scsi; +Cc: linux-kernel

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

Signed-off-by: Zhenzhong Duan <zhenzhong.duan@oracle.com>

---
 sas_scsi_host.c |    1 +
 1 file changed, 1 insertion(+)



[-- Attachment #2: declare-firmware-in-libsas.patch --]
[-- Type: text/x-patch, Size: 463 bytes --]

diff -up linux-2.6/drivers/scsi/libsas/sas_scsi_host.c.origfw linux-2.6/drivers/scsi/libsas/sas_scsi_host.c
--- linux-2.6/drivers/scsi/libsas/sas_scsi_host.c.origfw	2011-01-04 14:11:18.000000000 +0800
+++ linux-2.6/drivers/scsi/libsas/sas_scsi_host.c	2011-01-04 14:11:35.000000000 +0800
@@ -1110,6 +1110,7 @@ out:
 	release_firmware(fw);
 	return res;
 }
+MODULE_FIRMWARE("sas_addr");
 EXPORT_SYMBOL_GPL(sas_request_addr);
 
 EXPORT_SYMBOL_GPL(sas_queuecommand);

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

* Re: declare MODULE_FIRMWARE in libsas
  2011-01-04  7:43 declare MODULE_FIRMWARE in libsas DuanZhenzhong
@ 2011-01-04 14:08 ` James Bottomley
  2011-01-04 17:45   ` Jeff Garzik
  0 siblings, 1 reply; 9+ messages in thread
From: James Bottomley @ 2011-01-04 14:08 UTC (permalink / raw)
  To: DuanZhenzhong; +Cc: linux-scsi, linux-kernel

On Tue, 2011-01-04 at 15:43 +0800, DuanZhenzhong wrote:
> Signed-off-by: Zhenzhong Duan <zhenzhong.duan@oracle.com>
> 
> ---

Description?  Since libsas has no firmware, surely some explanation is
required.

James



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

* Re: declare MODULE_FIRMWARE in libsas
  2011-01-04 14:08 ` James Bottomley
@ 2011-01-04 17:45   ` Jeff Garzik
  2011-01-05  3:18     ` DuanZhenzhong
  0 siblings, 1 reply; 9+ messages in thread
From: Jeff Garzik @ 2011-01-04 17:45 UTC (permalink / raw)
  To: James Bottomley; +Cc: DuanZhenzhong, linux-scsi, linux-kernel

On 01/04/2011 09:08 AM, James Bottomley wrote:
> On Tue, 2011-01-04 at 15:43 +0800, DuanZhenzhong wrote:
>> Signed-off-by: Zhenzhong Duan<zhenzhong.duan@oracle.com>
>>
>> ---
>
> Description?  Since libsas has no firmware, surely some explanation is
> required.

Indeed.  Looks bogus at first glance?



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

* Re: declare MODULE_FIRMWARE in libsas
  2011-01-04 17:45   ` Jeff Garzik
@ 2011-01-05  3:18     ` DuanZhenzhong
  2011-01-05  4:36       ` James Bottomley
  2011-01-05  4:47       ` Américo Wang
  0 siblings, 2 replies; 9+ messages in thread
From: DuanZhenzhong @ 2011-01-05  3:18 UTC (permalink / raw)
  To: Jeff Garzik; +Cc: James Bottomley, linux-scsi, linux-kernel

Jeff Garzik 写道:
> On 01/04/2011 09:08 AM, James Bottomley wrote:
>> On Tue, 2011-01-04 at 15:43 +0800, DuanZhenzhong wrote:
>>> Signed-off-by: Zhenzhong Duan<zhenzhong.duan@oracle.com>
>>>
>>> ---
>>
>> Description?  Since libsas has no firmware, surely some explanation is
>> required.
>
> Indeed.  Looks bogus at first glance?
>
>
I was finding all requested but not exported firmware in scsi driver for 
generating dump initrd use.
In sas_scsi_host.c, request_firmware is called with "sas_addr", sas_addr 
neither builtin nor exported. Don't sas_addr a firmware? Please correct 
me. thanks


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

* Re: declare MODULE_FIRMWARE in libsas
  2011-01-05  3:18     ` DuanZhenzhong
@ 2011-01-05  4:36       ` James Bottomley
  2011-01-05  5:27         ` DuanZhenzhong
  2011-01-05  4:47       ` Américo Wang
  1 sibling, 1 reply; 9+ messages in thread
From: James Bottomley @ 2011-01-05  4:36 UTC (permalink / raw)
  To: DuanZhenzhong; +Cc: Jeff Garzik, linux-scsi, linux-kernel

On Wed, 2011-01-05 at 11:18 +0800, DuanZhenzhong wrote:
> Jeff Garzik 写道:
> > On 01/04/2011 09:08 AM, James Bottomley wrote:
> >> On Tue, 2011-01-04 at 15:43 +0800, DuanZhenzhong wrote:
> >>> Signed-off-by: Zhenzhong Duan<zhenzhong.duan@oracle.com>
> >>>
> >>> ---
> >>
> >> Description?  Since libsas has no firmware, surely some explanation is
> >> required.
> >
> > Indeed.  Looks bogus at first glance?
> >
> >
> I was finding all requested but not exported firmware in scsi driver for 
> generating dump initrd use.
> In sas_scsi_host.c, request_firmware is called with "sas_addr", sas_addr 
> neither builtin nor exported. Don't sas_addr a firmware? Please correct 
> me. thanks

No, it's not requesting any firmware ... it's a slight misuse of the
firmware mechanism that allows a libsas based driver to be given a SAS
address if it doesn't have an internal nsvram to store one.

James



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

* Re: declare MODULE_FIRMWARE in libsas
  2011-01-05  3:18     ` DuanZhenzhong
  2011-01-05  4:36       ` James Bottomley
@ 2011-01-05  4:47       ` Américo Wang
  2011-01-05  5:28         ` DuanZhenzhong
  1 sibling, 1 reply; 9+ messages in thread
From: Américo Wang @ 2011-01-05  4:47 UTC (permalink / raw)
  To: DuanZhenzhong; +Cc: Jeff Garzik, James Bottomley, linux-scsi, linux-kernel

On Wed, Jan 05, 2011 at 11:18:45AM +0800, DuanZhenzhong wrote:
>Jeff Garzik 写道:
>>On 01/04/2011 09:08 AM, James Bottomley wrote:
>>>On Tue, 2011-01-04 at 15:43 +0800, DuanZhenzhong wrote:
>>>>Signed-off-by: Zhenzhong Duan<zhenzhong.duan@oracle.com>
>>>>
>>>>---
>>>
>>>Description?  Since libsas has no firmware, surely some explanation is
>>>required.
>>
>>Indeed.  Looks bogus at first glance?
>>
>>
>I was finding all requested but not exported firmware in scsi driver
>for generating dump initrd use.
>In sas_scsi_host.c, request_firmware is called with "sas_addr",
>sas_addr neither builtin nor exported. Don't sas_addr a firmware?
>Please correct me. thanks
>

But once you export it, it needs to be found in fireware/ directory...

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

* Re: declare MODULE_FIRMWARE in libsas
  2011-01-05  4:36       ` James Bottomley
@ 2011-01-05  5:27         ` DuanZhenzhong
  0 siblings, 0 replies; 9+ messages in thread
From: DuanZhenzhong @ 2011-01-05  5:27 UTC (permalink / raw)
  To: James Bottomley; +Cc: Jeff Garzik, linux-scsi, linux-kernel

James Bottomley 写道:
> On Wed, 2011-01-05 at 11:18 +0800, DuanZhenzhong wrote:
>   
>> Jeff Garzik 写道:
>>     
>>> On 01/04/2011 09:08 AM, James Bottomley wrote:
>>>       
>>>> On Tue, 2011-01-04 at 15:43 +0800, DuanZhenzhong wrote:
>>>>         
>>>>> Signed-off-by: Zhenzhong Duan<zhenzhong.duan@oracle.com>
>>>>>
>>>>> ---
>>>>>           
>>>> Description?  Since libsas has no firmware, surely some explanation is
>>>> required.
>>>>         
>>> Indeed.  Looks bogus at first glance?
>>>
>>>
>>>       
>> I was finding all requested but not exported firmware in scsi driver for 
>> generating dump initrd use.
>> In sas_scsi_host.c, request_firmware is called with "sas_addr", sas_addr 
>> neither builtin nor exported. Don't sas_addr a firmware? Please correct 
>> me. thanks
>>     
>
> No, it's not requesting any firmware ... it's a slight misuse of the
> firmware mechanism that allows a libsas based driver to be given a SAS
> address if it doesn't have an internal nsvram to store one.
>
> James
>
>
>   
I see, thanks

-- 
Regards
zhenzhong


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

* Re: declare MODULE_FIRMWARE in libsas
  2011-01-05  4:47       ` Américo Wang
@ 2011-01-05  5:28         ` DuanZhenzhong
  2011-01-05  5:42           ` Américo Wang
  0 siblings, 1 reply; 9+ messages in thread
From: DuanZhenzhong @ 2011-01-05  5:28 UTC (permalink / raw)
  To: Américo Wang; +Cc: Jeff Garzik, James Bottomley, linux-scsi, linux-kernel

Américo Wang 写道:
> On Wed, Jan 05, 2011 at 11:18:45AM +0800, DuanZhenzhong wrote:
>   
>> Jeff Garzik 写道:
>>     
>>> On 01/04/2011 09:08 AM, James Bottomley wrote:
>>>       
>>>> On Tue, 2011-01-04 at 15:43 +0800, DuanZhenzhong wrote:
>>>>         
>>>>> Signed-off-by: Zhenzhong Duan<zhenzhong.duan@oracle.com>
>>>>>
>>>>> ---
>>>>>           
>>>> Description?  Since libsas has no firmware, surely some explanation is
>>>> required.
>>>>         
>>> Indeed.  Looks bogus at first glance?
>>>
>>>
>>>       
>> I was finding all requested but not exported firmware in scsi driver
>> for generating dump initrd use.
>> In sas_scsi_host.c, request_firmware is called with "sas_addr",
>> sas_addr neither builtin nor exported. Don't sas_addr a firmware?
>> Please correct me. thanks
>>
>>     
>
> But once you export it, it needs to be found in fireware/ directory...
>   
Not exactly, firmware/ dir only have a subset of all needed firmware. 
Also one can load firmware manually from anywhere

-- 
Regards
zhenzhong


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

* Re: declare MODULE_FIRMWARE in libsas
  2011-01-05  5:28         ` DuanZhenzhong
@ 2011-01-05  5:42           ` Américo Wang
  0 siblings, 0 replies; 9+ messages in thread
From: Américo Wang @ 2011-01-05  5:42 UTC (permalink / raw)
  To: DuanZhenzhong
  Cc: Américo Wang, Jeff Garzik, James Bottomley, linux-scsi,
	linux-kernel

On Wed, Jan 05, 2011 at 01:28:26PM +0800, DuanZhenzhong wrote:
>Américo Wang 写道:
>>On Wed, Jan 05, 2011 at 11:18:45AM +0800, DuanZhenzhong wrote:
>>>Jeff Garzik 写道:
>>>>On 01/04/2011 09:08 AM, James Bottomley wrote:
>>>>>On Tue, 2011-01-04 at 15:43 +0800, DuanZhenzhong wrote:
>>>>>>Signed-off-by: Zhenzhong Duan<zhenzhong.duan@oracle.com>
>>>>>>
>>>>>>---
>>>>>Description?  Since libsas has no firmware, surely some explanation is
>>>>>required.
>>>>Indeed.  Looks bogus at first glance?
>>>>
>>>>
>>>I was finding all requested but not exported firmware in scsi driver
>>>for generating dump initrd use.
>>>In sas_scsi_host.c, request_firmware is called with "sas_addr",
>>>sas_addr neither builtin nor exported. Don't sas_addr a firmware?
>>>Please correct me. thanks
>>>
>>
>>But once you export it, it needs to be found in fireware/ directory...
>Not exactly, firmware/ dir only have a subset of all needed firmware.
>Also one can load firmware manually from anywhere
>

Then it should not be exported, otherwise user-space will get confused.
We have a script to parse modinfo output to get the firmwares of a module.

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

end of thread, other threads:[~2011-01-05  5:42 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-01-04  7:43 declare MODULE_FIRMWARE in libsas DuanZhenzhong
2011-01-04 14:08 ` James Bottomley
2011-01-04 17:45   ` Jeff Garzik
2011-01-05  3:18     ` DuanZhenzhong
2011-01-05  4:36       ` James Bottomley
2011-01-05  5:27         ` DuanZhenzhong
2011-01-05  4:47       ` Américo Wang
2011-01-05  5:28         ` DuanZhenzhong
2011-01-05  5:42           ` Américo Wang

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