diff options
author | Klemens Nanni <kn@cvs.openbsd.org> | 2022-10-21 17:45:41 +0000 |
---|---|---|
committer | Klemens Nanni <kn@cvs.openbsd.org> | 2022-10-21 17:45:41 +0000 |
commit | c7dc0358a85f8024ae81bed8fdd3657084a13140 (patch) | |
tree | 5179caf44ed869f6bd043a3b5bd7d803f4a05bb9 | |
parent | 5e1c0ab96b51327fd82680c8bdef8786b8203f50 (diff) |
constify global identity tables
ah{c,d}_find_pci_device() already return their members as const.
OK krw
-rw-r--r-- | sys/dev/ic/aic79xx.h | 4 | ||||
-rw-r--r-- | sys/dev/ic/aic7xxxvar.h | 6 | ||||
-rw-r--r-- | sys/dev/pci/ahc_pci.c | 6 | ||||
-rw-r--r-- | sys/dev/pci/ahd_pci.c | 4 |
4 files changed, 10 insertions, 10 deletions
diff --git a/sys/dev/ic/aic79xx.h b/sys/dev/ic/aic79xx.h index dd7ae5c5cb5..f629fc66644 100644 --- a/sys/dev/ic/aic79xx.h +++ b/sys/dev/ic/aic79xx.h @@ -1,4 +1,4 @@ -/* $OpenBSD: aic79xx.h,v 1.29 2022/01/09 05:42:38 jsg Exp $ */ +/* $OpenBSD: aic79xx.h,v 1.30 2022/10/21 17:45:40 kn Exp $ */ /* * Copyright (c) 2004 Milos Urbanek, Kenneth R. Westerback & Marco Peereboom @@ -1316,7 +1316,7 @@ struct ahd_pci_identity { uint64_t id_mask; ahd_device_setup_t *setup; }; -extern struct ahd_pci_identity ahd_pci_ident_table []; +extern const struct ahd_pci_identity ahd_pci_ident_table[]; extern const u_int ahd_num_pci_devs; /*************************** Function Declarations ****************************/ diff --git a/sys/dev/ic/aic7xxxvar.h b/sys/dev/ic/aic7xxxvar.h index 188c1a03959..0c4668fad0d 100644 --- a/sys/dev/ic/aic7xxxvar.h +++ b/sys/dev/ic/aic7xxxvar.h @@ -1,4 +1,4 @@ -/* $OpenBSD: aic7xxxvar.h,v 1.37 2022/01/09 05:42:38 jsg Exp $ */ +/* $OpenBSD: aic7xxxvar.h,v 1.38 2022/10/21 17:45:40 kn Exp $ */ /* * Core definitions and data structures shareable across OS platforms. * @@ -38,7 +38,7 @@ * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGES. * - * $Id: aic7xxxvar.h,v 1.37 2022/01/09 05:42:38 jsg Exp $ + * $Id: aic7xxxvar.h,v 1.38 2022/10/21 17:45:40 kn Exp $ * * $FreeBSD: src/sys/dev/aic7xxx/aic7xxx.h,v 1.50 2003/12/17 00:02:09 gibbs Exp $ */ @@ -1161,7 +1161,7 @@ struct ahc_pci_identity { uint64_t id_mask; ahc_device_setup_t *setup; }; -extern struct ahc_pci_identity ahc_pci_ident_table[]; +extern const struct ahc_pci_identity ahc_pci_ident_table[]; /***************************** VL/EISA Declarations ***************************/ struct aic7770_identity { diff --git a/sys/dev/pci/ahc_pci.c b/sys/dev/pci/ahc_pci.c index d131b2a4078..373e87e89f4 100644 --- a/sys/dev/pci/ahc_pci.c +++ b/sys/dev/pci/ahc_pci.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ahc_pci.c,v 1.62 2022/03/11 18:00:45 mpi Exp $ */ +/* $OpenBSD: ahc_pci.c,v 1.63 2022/10/21 17:45:40 kn Exp $ */ /* $NetBSD: ahc_pci.c,v 1.43 2003/08/18 09:16:22 taca Exp $ */ /* @@ -42,7 +42,7 @@ * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGES. * - * $Id: ahc_pci.c,v 1.62 2022/03/11 18:00:45 mpi Exp $ + * $Id: ahc_pci.c,v 1.63 2022/10/21 17:45:40 kn Exp $ * * //depot/aic7xxx/aic7xxx/aic7xxx_pci.c#57 $ * @@ -261,7 +261,7 @@ static ahc_device_setup_t ahc_aha394XX_setup; static ahc_device_setup_t ahc_aha494XX_setup; static ahc_device_setup_t ahc_aha398XX_setup; -struct ahc_pci_identity ahc_pci_ident_table [] = +const struct ahc_pci_identity ahc_pci_ident_table [] = { /* aic7850 based controllers */ { diff --git a/sys/dev/pci/ahd_pci.c b/sys/dev/pci/ahd_pci.c index bc6f3401129..b6b6affafed 100644 --- a/sys/dev/pci/ahd_pci.c +++ b/sys/dev/pci/ahd_pci.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ahd_pci.c,v 1.28 2022/03/11 18:00:45 mpi Exp $ */ +/* $OpenBSD: ahd_pci.c,v 1.29 2022/10/21 17:45:40 kn Exp $ */ /* * Copyright (c) 2004 Milos Urbanek, Kenneth R. Westerback & Marco Peereboom @@ -146,7 +146,7 @@ ahd_device_setup_t ahd_aic7901A_setup; ahd_device_setup_t ahd_aic7902_setup; ahd_device_setup_t ahd_aic790X_setup; -struct ahd_pci_identity ahd_pci_ident_table [] = +const struct ahd_pci_identity ahd_pci_ident_table[] = { /* aic7901 based controllers */ { |