via-velocity: use driver string instead of dev->name before register_netdev()
authorSven Hartge <sven@svenhartge.de>
Thu, 23 Oct 2008 13:03:44 +0000 (13:03 +0000)
committerJeff Garzik <jgarzik@redhat.com>
Mon, 27 Oct 2008 19:12:02 +0000 (15:12 -0400)
commit07b5f6a6fd0ce47390f7fbec966cd5c70127e597
treeeb8f4eac27042d469afe52c1dde7b686a0c2e29b
parent404b12c10d2f4d77649a193af2ec69f77b852926
via-velocity: use driver string instead of dev->name before register_netdev()

This patch corrects a message bug in the via-velocity driver which
bothered me for some time.

The messages printed during device init look like the following:

[    8.486422] eth%d: set value of parameter Wake On Lan options to 0
                  ^^!
[    8.487340] eth0: VIA Networking Velocity Family Gigabit Ethernet Adapter

Note the unresolved format string.

dev->name is unavailable before register_netdev, so use
dev_driver_string(&pdev->dev), which is also consistent with other
drivers.

"char *devname" parameters had to be converted to "const char *devname" to
be consistent with dev_driver_string return value.

Signed-off-by: Sven Hartge <sven@svenhartge.de>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
drivers/net/via-velocity.c