aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net
diff options
context:
space:
mode:
authorDominik Brodowski <linux@dominikbrodowski.net>2006-01-15 05:18:12 -0500
committerDominik Brodowski <linux@dominikbrodowski.net>2006-03-31 10:15:53 -0500
commit4bbed5231468014b500b048d7370a1c6c349231a (patch)
tree5dfafd6a932201fbbfbb2466c11f5392b3240342 /drivers/net
parent8661bb5b4af1849c1f5a4e80c4e275fd13c155d6 (diff)
[PATCH] pcmcia: remove export of pcmcia_release_configuration
Handle the _modifying_ operation sm91c92_cs requires in pcmcia_modify_configuration, so that the only remaining users of pcmcia_release_configuration() are within the pcmcia core module. Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/pcmcia/smc91c92_cs.c29
1 files changed, 11 insertions, 18 deletions
diff --git a/drivers/net/pcmcia/smc91c92_cs.c b/drivers/net/pcmcia/smc91c92_cs.c
index 84e18bbed9d2..86942c09d8da 100644
--- a/drivers/net/pcmcia/smc91c92_cs.c
+++ b/drivers/net/pcmcia/smc91c92_cs.c
@@ -874,11 +874,8 @@ static int smc91c92_suspend(struct pcmcia_device *p_dev)
874 dev_link_t *link = dev_to_instance(p_dev); 874 dev_link_t *link = dev_to_instance(p_dev);
875 struct net_device *dev = link->priv; 875 struct net_device *dev = link->priv;
876 876
877 if (link->state & DEV_CONFIG) { 877 if ((link->state & DEV_CONFIG) && (link->open))
878 if (link->open) 878 netif_device_detach(dev);
879 netif_device_detach(dev);
880 pcmcia_release_configuration(link->handle);
881 }
882 879
883 return 0; 880 return 0;
884} 881}
@@ -894,7 +891,6 @@ static int smc91c92_resume(struct pcmcia_device *p_dev)
894 if ((smc->manfid == MANFID_MEGAHERTZ) && 891 if ((smc->manfid == MANFID_MEGAHERTZ) &&
895 (smc->cardid == PRODID_MEGAHERTZ_EM3288)) 892 (smc->cardid == PRODID_MEGAHERTZ_EM3288))
896 mhz_3288_power(link); 893 mhz_3288_power(link);
897 pcmcia_request_configuration(link->handle, &link->conf);
898 if (smc->manfid == MANFID_MOTOROLA) 894 if (smc->manfid == MANFID_MOTOROLA)
899 mot_config(link); 895 mot_config(link);
900 if ((smc->manfid == MANFID_OSITECH) && 896 if ((smc->manfid == MANFID_OSITECH) &&
@@ -963,18 +959,15 @@ static int check_sig(dev_link_t *link)
963 } 959 }
964 960
965 if (width) { 961 if (width) {
966 printk(KERN_INFO "smc91c92_cs: using 8-bit IO window.\n"); 962 modconf_t mod = {
967 /* call pcmcia_release_configuration() in _suspend */ 963 .Attributes = CONF_IO_CHANGE_WIDTH,
968 smc91c92_suspend(link->handle); 964 };
969 965 printk(KERN_INFO "smc91c92_cs: using 8-bit IO window.\n");
970 link->io.Attributes1 = IO_DATA_PATH_WIDTH_8; 966
971 link->handle->socket->io[0].res->flags &= ~IO_DATA_PATH_WIDTH; 967 smc91c92_suspend(link->handle);
972 link->handle->socket->io[0].res->flags |= IO_DATA_PATH_WIDTH_8; 968 pcmcia_modify_configuration(link->handle, &mod);
973 969 smc91c92_resume(link->handle);
974 /* call pcmcia_request_configuration() in _resume, it handles the 970 return check_sig(link);
975 * flag update */
976 smc91c92_resume(link->handle);
977 return check_sig(link);
978 } 971 }
979 return -ENODEV; 972 return -ENODEV;
980} 973}