aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/libertas/main.c
diff options
context:
space:
mode:
authorJavier Cardona <javier@cozybit.com>2008-05-18 00:01:24 -0400
committerJohn W. Linville <linville@tuxdriver.com>2008-05-21 21:47:39 -0400
commit15dbaac03e862ee746310832c8d8d694dc0427ee (patch)
tree3f9af03aadd22af9bdd6050d81eafeeda4132c9e /drivers/net/wireless/libertas/main.c
parentedaea5ce05ca804cc55438c586ca2f947d49f56f (diff)
libertas: sysfs interface for accessing non-volatile configuration
This will create the following sysfs directories: /sys/class/net/mshX ... |-- boot_options | |-- bootflag | `-- boottime ... |-- mesh_ie | |-- capability | |-- mesh_id | |-- metric_id | `-- protocol_id Signed-off-by: Javier Cardona <javier@cozybit.com> Signed-off-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/libertas/main.c')
-rw-r--r--drivers/net/wireless/libertas/main.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/net/wireless/libertas/main.c b/drivers/net/wireless/libertas/main.c
index 01299c8ed27c..db246d0a1eda 100644
--- a/drivers/net/wireless/libertas/main.c
+++ b/drivers/net/wireless/libertas/main.c
@@ -1302,8 +1302,9 @@ void lbs_stop_card(struct lbs_private *priv)
1302 1302
1303 lbs_debugfs_remove_one(priv); 1303 lbs_debugfs_remove_one(priv);
1304 device_remove_file(&dev->dev, &dev_attr_lbs_rtap); 1304 device_remove_file(&dev->dev, &dev_attr_lbs_rtap);
1305 if (priv->mesh_tlv) 1305 if (priv->mesh_tlv) {
1306 device_remove_file(&dev->dev, &dev_attr_lbs_mesh); 1306 device_remove_file(&dev->dev, &dev_attr_lbs_mesh);
1307 }
1307 1308
1308 /* Flush pending command nodes */ 1309 /* Flush pending command nodes */
1309 del_timer_sync(&priv->command_timer); 1310 del_timer_sync(&priv->command_timer);
@@ -1372,6 +1373,8 @@ static int lbs_add_mesh(struct lbs_private *priv)
1372 if (ret) 1373 if (ret)
1373 goto err_unregister; 1374 goto err_unregister;
1374 1375
1376 lbs_persist_config_init(mesh_dev);
1377
1375 /* Everything successful */ 1378 /* Everything successful */
1376 ret = 0; 1379 ret = 0;
1377 goto done; 1380 goto done;
@@ -1398,8 +1401,9 @@ static void lbs_remove_mesh(struct lbs_private *priv)
1398 1401
1399 lbs_deb_enter(LBS_DEB_MESH); 1402 lbs_deb_enter(LBS_DEB_MESH);
1400 netif_stop_queue(mesh_dev); 1403 netif_stop_queue(mesh_dev);
1401 netif_carrier_off(priv->mesh_dev); 1404 netif_carrier_off(mesh_dev);
1402 sysfs_remove_group(&(mesh_dev->dev.kobj), &lbs_mesh_attr_group); 1405 sysfs_remove_group(&(mesh_dev->dev.kobj), &lbs_mesh_attr_group);
1406 lbs_persist_config_remove(mesh_dev);
1403 unregister_netdev(mesh_dev); 1407 unregister_netdev(mesh_dev);
1404 priv->mesh_dev = NULL; 1408 priv->mesh_dev = NULL;
1405 free_netdev(mesh_dev); 1409 free_netdev(mesh_dev);