Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev Cardbus_free_tag() and cardbus_free_tag() are no-ops...
details: https://anonhg.NetBSD.org/src/rev/2967817a87a8
branches: trunk
changeset: 752395:2967817a87a8
user: dyoung <dyoung%NetBSD.org@localhost>
date: Thu Feb 25 00:47:39 2010 +0000
description:
Cardbus_free_tag() and cardbus_free_tag() are no-ops, so get rid of them
to simplify the code a bit.
diffstat:
sys/dev/cardbus/cardbus.c | 6 ++----
sys/dev/cardbus/cardbus_map.c | 11 ++---------
sys/dev/cardbus/cardbusvar.h | 10 ++--------
sys/dev/cardbus/siisata_cardbus.c | 5 ++---
sys/dev/pci/pccbb.c | 11 ++---------
5 files changed, 10 insertions(+), 33 deletions(-)
diffs (196 lines):
diff -r 376ec77e34ed -r 2967817a87a8 sys/dev/cardbus/cardbus.c
--- a/sys/dev/cardbus/cardbus.c Thu Feb 25 00:18:44 2010 +0000
+++ b/sys/dev/cardbus/cardbus.c Thu Feb 25 00:47:39 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cardbus.c,v 1.102 2010/02/24 23:38:40 dyoung Exp $ */
+/* $NetBSD: cardbus.c,v 1.103 2010/02/25 00:47:39 dyoung Exp $ */
/*
* Copyright (c) 1997, 1998, 1999 and 2000
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cardbus.c,v 1.102 2010/02/24 23:38:40 dyoung Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cardbus.c,v 1.103 2010/02/25 00:47:39 dyoung Exp $");
#include "opt_cardbus.h"
@@ -826,8 +826,6 @@
if ((ct = sc->sc_funcs[func]) != NULL)
Cardbus_conf_write(ct, tag, CARDBUS_BHLC_REG, ct->ct_bhlc);
- cardbus_free_tag(cc, cf, tag);
-
DPRINTF(("%x\n", sc->sc_poweron_func));
return (0);
diff -r 376ec77e34ed -r 2967817a87a8 sys/dev/cardbus/cardbus_map.c
--- a/sys/dev/cardbus/cardbus_map.c Thu Feb 25 00:18:44 2010 +0000
+++ b/sys/dev/cardbus/cardbus_map.c Thu Feb 25 00:47:39 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cardbus_map.c,v 1.32 2010/02/24 19:52:51 dyoung Exp $ */
+/* $NetBSD: cardbus_map.c,v 1.33 2010/02/25 00:47:39 dyoung Exp $ */
/*
* Copyright (c) 1999 and 2000
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cardbus_map.c,v 1.32 2010/02/24 19:52:51 dyoung Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cardbus_map.c,v 1.33 2010/02/25 00:47:39 dyoung Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -304,7 +304,6 @@
if (sizep != 0) {
*sizep = size;
}
- cardbus_free_tag(cc, cf, tag);
return 0;
}
@@ -357,8 +356,6 @@
(*cf->cardbus_space_free)(cc, rbustag, handle, size);
#endif
- cardbus_free_tag(cc, cf, cardbustag);
-
return st;
}
@@ -387,8 +384,6 @@
DPRINTF(("cardbus_save_bar: %x %x\n", ct->ct_bar[0], ct->ct_bar[1]));
- Cardbus_free_tag(ct, tag);
-
return 0;
}
@@ -413,7 +408,5 @@
cardbus_conf_write(cc, cf, tag, CARDBUS_BASE4_REG, ct->ct_bar[4]);
cardbus_conf_write(cc, cf, tag, CARDBUS_BASE5_REG, ct->ct_bar[5]);
- Cardbus_free_tag(ct, tag);
-
return 0;
}
diff -r 376ec77e34ed -r 2967817a87a8 sys/dev/cardbus/cardbusvar.h
--- a/sys/dev/cardbus/cardbusvar.h Thu Feb 25 00:18:44 2010 +0000
+++ b/sys/dev/cardbus/cardbusvar.h Thu Feb 25 00:47:39 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cardbusvar.h,v 1.46 2010/02/24 23:38:40 dyoung Exp $ */
+/* $NetBSD: cardbusvar.h,v 1.47 2010/02/25 00:47:39 dyoung Exp $ */
/*
* Copyright (c) 1998, 1999 and 2000
@@ -47,8 +47,7 @@
* The child devices can use those functions. The contained functions
* are: cardbus_space_alloc, cardbus_space_free,
* cardbus_intr_establish, cardbus_intr_disestablish, cardbus_ctrl,
- * cardbus_power, cardbus_make_tag, cardbus_free_tag and
- * cardbus_conf_write.
+ * cardbus_power, cardbus_make_tag, and cardbus_conf_write.
*
* int (*cardbus_space_alloc)(cardbus_chipset_tag_t ct, rbus_tag_t rb,
* bus_addr_t addr, bus_size_t size,
@@ -71,7 +70,6 @@
*
* pcitag_t (*cardbus_make_tag)(cardbus_chipset_tag_t ct,
* int busno, int functionno);
- * void (*cardbus_free_tag)(cardbus_chipset_tag_t ct, pcitag_t tag);
* pcireg_t (*cardbus_conf_read)(cardbus_chipset_tag_t ct,
* pcitag_t tag, int offs);
* void (*cardbus_conf_write)(cardbus_chipset_tag_t ct,
@@ -90,7 +88,6 @@
int (*cardbus_power)(cardbus_chipset_tag_t, int);
pcitag_t (*cardbus_make_tag)(cardbus_chipset_tag_t, int, int);
- void (*cardbus_free_tag)(cardbus_chipset_tag_t, pcitag_t);
pcireg_t (*cardbus_conf_read)(cardbus_chipset_tag_t,
pcitag_t, int);
void (*cardbus_conf_write)(cardbus_chipset_tag_t, pcitag_t,
@@ -346,9 +343,6 @@
#define Cardbus_make_tag(ct) (*(ct)->ct_cf->cardbus_make_tag)((ct)->ct_cc, (ct)->ct_bus, (ct)->ct_func)
#define cardbus_make_tag(cc, cf, bus, function) ((cf)->cardbus_make_tag)((cc), (bus), (function))
-#define Cardbus_free_tag(ct, tag) (*(ct)->ct_cf->cardbus_free_tag)((ct)->ct_cc, (tag))
-#define cardbus_free_tag(cc, cf, tag) (*(cf)->cardbus_free_tag)(cc, (tag))
-
#define Cardbus_conf_read(ct, tag, offs) (*(ct)->ct_cf->cardbus_conf_read)((ct)->ct_cc, (tag), (offs))
#define cardbus_conf_read(cc, cf, tag, offs) ((cf)->cardbus_conf_read)((cc), (tag), (offs))
#define Cardbus_conf_write(ct, tag, offs, val) (*(ct)->ct_cf->cardbus_conf_write)((ct)->ct_cc, (tag), (offs), (val))
diff -r 376ec77e34ed -r 2967817a87a8 sys/dev/cardbus/siisata_cardbus.c
--- a/sys/dev/cardbus/siisata_cardbus.c Thu Feb 25 00:18:44 2010 +0000
+++ b/sys/dev/cardbus/siisata_cardbus.c Thu Feb 25 00:47:39 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: siisata_cardbus.c,v 1.5 2010/02/24 19:52:52 dyoung Exp $ */
+/* $NetBSD: siisata_cardbus.c,v 1.6 2010/02/25 00:47:39 dyoung Exp $ */
/* Id: siisata_pci.c,v 1.11 2008/05/21 16:20:11 jakllsch Exp */
/*
@@ -52,7 +52,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: siisata_cardbus.c,v 1.5 2010/02/24 19:52:52 dyoung Exp $");
+__KERNEL_RCSID(0, "$NetBSD: siisata_cardbus.c,v 1.6 2010/02/25 00:47:39 dyoung Exp $");
#include <sys/types.h>
#include <sys/malloc.h>
@@ -291,7 +291,6 @@
csc->sc_prsize);
csc->sc_prsize = 0;
}
- cardbus_free_tag(cc, cf, ctag);
return 0;
}
diff -r 376ec77e34ed -r 2967817a87a8 sys/dev/pci/pccbb.c
--- a/sys/dev/pci/pccbb.c Thu Feb 25 00:18:44 2010 +0000
+++ b/sys/dev/pci/pccbb.c Thu Feb 25 00:47:39 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pccbb.c,v 1.195 2010/02/24 23:38:40 dyoung Exp $ */
+/* $NetBSD: pccbb.c,v 1.196 2010/02/25 00:47:40 dyoung Exp $ */
/*
* Copyright (c) 1998, 1999 and 2000
@@ -26,7 +26,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pccbb.c,v 1.195 2010/02/24 23:38:40 dyoung Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pccbb.c,v 1.196 2010/02/25 00:47:40 dyoung Exp $");
/*
#define CBB_DEBUG
@@ -134,7 +134,6 @@
static void pccbb_cb_intr_disestablish(cardbus_chipset_tag_t ct, void *ih);
static pcitag_t pccbb_make_tag(cardbus_chipset_tag_t, int, int);
-static void pccbb_free_tag(cardbus_chipset_tag_t, pcitag_t);
static pcireg_t pccbb_conf_read(cardbus_chipset_tag_t, pcitag_t, int);
static void pccbb_conf_write(cardbus_chipset_tag_t, pcitag_t, int,
pcireg_t);
@@ -237,7 +236,6 @@
pccbb_ctrl,
pccbb_power_ct,
pccbb_make_tag,
- pccbb_free_tag,
pccbb_conf_read,
pccbb_conf_write,
};
@@ -1910,11 +1908,6 @@
return pci_make_tag(sc->sc_pc, busno, 0, function);
}
-static void
-pccbb_free_tag(cardbus_chipset_tag_t cc, pcitag_t tag)
-{
-}
-
/*
* pccbb_conf_read
*
Home |
Main Index |
Thread Index |
Old Index