Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 85592
b: refs/heads/master
c: 09dde54
h: refs/heads/master
v: v3
  • Loading branch information
Masakazu Mokuno authored and Jeff Garzik committed Feb 11, 2008
1 parent 8ce8712 commit 96732f6
Show file tree
Hide file tree
Showing 7 changed files with 3,118 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 589866f9f1cb14273b644993d362ec7845007f94
refs/heads/master: 09dde54c6a69d4f9ea1213923b93aeae7020f8b6
10 changes: 10 additions & 0 deletions trunk/drivers/net/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -2352,6 +2352,16 @@ config GELIC_NET
To compile this driver as a module, choose M here: the
module will be called ps3_gelic.

config GELIC_WIRELESS
bool "PS3 Wireless support"
depends on GELIC_NET
help
This option adds the support for the wireless feature of PS3.
If you have the wireless-less model of PS3 or have no plan to
use wireless feature, disabling this option saves memory. As
the driver automatically distinguishes the models, you can
safely enable this option even if you have a wireless-less model.

config GIANFAR
tristate "Gianfar Ethernet"
depends on FSL_SOC
Expand Down
3 changes: 2 additions & 1 deletion trunk/drivers/net/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,8 @@ obj-$(CONFIG_BNX2X) += bnx2x.o
spidernet-y += spider_net.o spider_net_ethtool.o
obj-$(CONFIG_SPIDER_NET) += spidernet.o sungem_phy.o
obj-$(CONFIG_GELIC_NET) += ps3_gelic.o
ps3_gelic-objs += ps3_gelic_net.o
gelic_wireless-$(CONFIG_GELIC_WIRELESS) += ps3_gelic_wireless.o
ps3_gelic-objs += ps3_gelic_net.o $(gelic_wireless-y)
obj-$(CONFIG_TC35815) += tc35815.o
obj-$(CONFIG_SKGE) += skge.o
obj-$(CONFIG_SKY2) += sky2.o
Expand Down
18 changes: 17 additions & 1 deletion trunk/drivers/net/ps3_gelic_net.c
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,10 @@
#include <asm/lv1call.h>

#include "ps3_gelic_net.h"
#include "ps3_gelic_wireless.h"

#define DRV_NAME "Gelic Network Driver"
#define DRV_VERSION "1.1"
#define DRV_VERSION "2.0"

MODULE_AUTHOR("SCE Inc.");
MODULE_DESCRIPTION("Gelic Network driver");
Expand Down Expand Up @@ -1154,6 +1155,12 @@ static irqreturn_t gelic_card_interrupt(int irq, void *ptr)
if (status & GELIC_CARD_PORT_STATUS_CHANGED)
gelic_card_get_ether_port_status(card, 1);

#ifdef CONFIG_GELIC_WIRELESS
if (status & (GELIC_CARD_WLAN_EVENT_RECEIVED |
GELIC_CARD_WLAN_COMMAND_COMPLETED))
gelic_wl_interrupt(card->netdev[GELIC_PORT_WIRELESS], status);
#endif

return IRQ_HANDLED;
}

Expand Down Expand Up @@ -1635,6 +1642,12 @@ static int ps3_gelic_driver_probe(struct ps3_system_bus_device *dev)
goto fail_setup_netdev;
}

#ifdef CONFIG_GELIC_WIRELESS
if (gelic_wl_driver_probe(card)) {
dev_dbg(&dev->core, "%s: WL init failed\n", __func__);
goto fail_setup_netdev;
}
#endif
pr_debug("%s: done\n", __func__);
return 0;

Expand Down Expand Up @@ -1674,6 +1687,9 @@ static int ps3_gelic_driver_remove(struct ps3_system_bus_device *dev)
struct net_device *netdev0;
pr_debug("%s: called\n", __func__);

#ifdef CONFIG_GELIC_WIRELESS
gelic_wl_driver_remove(card);
#endif
/* stop interrupt */
gelic_card_set_irq_mask(card, 0);

Expand Down
6 changes: 6 additions & 0 deletions trunk/drivers/net/ps3_gelic_net.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,8 @@
#define GELIC_CARD_RX_PROTECTION_ERR 0x0000000004000000L
#define GELIC_CARD_TX_TCP_UDP_CHECKSUM_ERR 0x0000000008000000L
#define GELIC_CARD_PORT_STATUS_CHANGED 0x0000000020000000L
#define GELIC_CARD_WLAN_EVENT_RECEIVED 0x0000000040000000L
#define GELIC_CARD_WLAN_COMMAND_COMPLETED 0x0000000080000000L
/* INT 0 */
#define GELIC_CARD_TX_FLAGGED_DESCR 0x0004000000000000L
#define GELIC_CARD_RX_FLAGGED_DESCR 0x0040000000000000L
Expand Down Expand Up @@ -180,6 +182,10 @@ enum gelic_lv1_net_control_code {
GELIC_LV1_GET_ETH_PORT_STATUS = 2,
GELIC_LV1_SET_NEGOTIATION_MODE = 3,
GELIC_LV1_GET_VLAN_ID = 4,
GELIC_LV1_GET_CHANNEL = 6,
GELIC_LV1_POST_WLAN_CMD = 9,
GELIC_LV1_GET_WLAN_CMD_RESULT = 10,
GELIC_LV1_GET_WLAN_EVENT = 11
};

/* status returened from GET_ETH_PORT_STATUS */
Expand Down
Loading

0 comments on commit 96732f6

Please sign in to comment.