* DMI: create dmi_get_slot()
@ 2008-01-25 20:13 Wim Van Sebroeck
2008-01-25 20:19 ` Len Brown
0 siblings, 1 reply; 2+ messages in thread
From: Wim Van Sebroeck @ 2008-01-25 20:13 UTC (permalink / raw)
To: Len Brown; +Cc: LKML
Hi Len,
I saw you added the dmi_get_slot function recently.
If I look in drivers/firmware/dmi_scan.c however I now see:
...
/**
* dmi_get_system_info - return DMI data value
* @field: data index (see enum dmi_field)
*
* Returns one DMI data value, can be used to perform
* complex DMI data checks.
*/
const char *dmi_get_system_info(int field)
{
return dmi_ident[field];
}
EXPORT_SYMBOL(dmi_get_system_info);
...
/**
* dmi_get_slot - return dmi_ident[slot]
* @slot: index into dmi_ident[]
*/
char *dmi_get_slot(int slot)
{
return(dmi_ident[slot]);
}
Didn't we duplicate code here?
Greetings,
Wim.
^ permalink raw reply [flat|nested] 2+ messages in thread* Re: DMI: create dmi_get_slot()
2008-01-25 20:13 DMI: create dmi_get_slot() Wim Van Sebroeck
@ 2008-01-25 20:19 ` Len Brown
0 siblings, 0 replies; 2+ messages in thread
From: Len Brown @ 2008-01-25 20:19 UTC (permalink / raw)
To: Wim Van Sebroeck; +Cc: LKML
On Friday 25 January 2008 15:13, Wim Van Sebroeck wrote:
> Hi Len,
>
> I saw you added the dmi_get_slot function recently.
> If I look in drivers/firmware/dmi_scan.c however I now see:
>
> ...
>
> /**
> * dmi_get_system_info - return DMI data value
> * @field: data index (see enum dmi_field)
> *
> * Returns one DMI data value, can be used to perform
> * complex DMI data checks.
> */
> const char *dmi_get_system_info(int field)
> {
> return dmi_ident[field];
> }
> EXPORT_SYMBOL(dmi_get_system_info);
>
> ...
>
> /**
> * dmi_get_slot - return dmi_ident[slot]
> * @slot: index into dmi_ident[]
> */
> char *dmi_get_slot(int slot)
> {
> return(dmi_ident[slot]);
> }
>
> Didn't we duplicate code here?
Yep, thanks for noticing, i'll delete the duplicate.
-Len
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-01-25 20:19 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-01-25 20:13 DMI: create dmi_get_slot() Wim Van Sebroeck
2008-01-25 20:19 ` Len Brown
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox