提交 6f75a9b6 编写于 作者: C Chas Williams 提交者: David S. Miller

atm: [fore200e] use MODULE_FIRMWARE() and other suggested cleanups

Signed-off-by: NChas Williams <chas@cmf.nrl.navy.mil>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 70eed75d
...@@ -2562,7 +2562,8 @@ fore200e_load_and_start_fw(struct fore200e* fore200e) ...@@ -2562,7 +2562,8 @@ fore200e_load_and_start_fw(struct fore200e* fore200e)
const struct firmware *firmware; const struct firmware *firmware;
struct device *device; struct device *device;
struct fw_header *fw_header; struct fw_header *fw_header;
u32 *fw_data, fw_size; const __le32 *fw_data;
u32 fw_size;
u32 __iomem *load_addr; u32 __iomem *load_addr;
char buf[48]; char buf[48];
int err = -ENODEV; int err = -ENODEV;
...@@ -2582,7 +2583,7 @@ fore200e_load_and_start_fw(struct fore200e* fore200e) ...@@ -2582,7 +2583,7 @@ fore200e_load_and_start_fw(struct fore200e* fore200e)
return err; return err;
} }
fw_data = (u32 *) firmware->data; fw_data = (__le32 *) firmware->data;
fw_size = firmware->size / sizeof(u32); fw_size = firmware->size / sizeof(u32);
fw_header = (struct fw_header *) firmware->data; fw_header = (struct fw_header *) firmware->data;
load_addr = fore200e->virt_base + le32_to_cpu(fw_header->load_offset); load_addr = fore200e->virt_base + le32_to_cpu(fw_header->load_offset);
...@@ -3199,6 +3200,14 @@ static const struct fore200e_bus fore200e_bus[] = { ...@@ -3199,6 +3200,14 @@ static const struct fore200e_bus fore200e_bus[] = {
{} {}
}; };
#ifdef MODULE_LICENSE
MODULE_LICENSE("GPL"); MODULE_LICENSE("GPL");
#ifdef CONFIG_PCI
#ifdef __LITTLE_ENDIAN__
MODULE_FIRMWARE("pca200e.bin");
#else
MODULE_FIRMWARE("pca200e_ecd.bin2");
#endif
#endif /* CONFIG_PCI */
#ifdef CONFIG_SBUS
MODULE_FIRMWARE("sba200e_ecd.bin2");
#endif #endif
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册