Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev Use designated initializers and a consistent termina...
details: https://anonhg.NetBSD.org/src/rev/ed3875008341
branches: trunk
changeset: 958732:ed3875008341
user: thorpej <thorpej%NetBSD.org@localhost>
date: Sun Jan 17 21:42:35 2021 +0000
description:
Use designated initializers and a consistent termination style in
compat_data[].
diffstat:
sys/dev/i2c/ac100.c | 9 +++++----
sys/dev/i2c/adadc.c | 9 +++++----
sys/dev/i2c/adm1021.c | 13 +++++++------
sys/dev/i2c/adm1026.c | 7 ++++---
sys/dev/i2c/anxedp.c | 9 +++++----
sys/dev/i2c/as3722.c | 9 +++++----
sys/dev/i2c/asms.c | 11 ++++++-----
sys/dev/i2c/axp20x.c | 9 +++++----
sys/dev/i2c/axp22x.c | 9 +++++----
sys/dev/i2c/cwfg.c | 9 +++++----
sys/dev/i2c/dbcool.c | 15 ++++++++-------
sys/dev/i2c/dstemp.c | 9 +++++----
sys/dev/i2c/em3027.c | 9 +++++----
sys/dev/i2c/es8316ac.c | 9 +++++----
sys/dev/i2c/fcu.c | 9 +++++----
sys/dev/i2c/hytp14.c | 7 ++++---
sys/dev/i2c/ihidev.c | 9 +++++----
sys/dev/i2c/lm75.c | 12 ++++++------
sys/dev/i2c/lm87.c | 17 +++++++++--------
sys/dev/i2c/max77620.c | 9 +++++----
sys/dev/i2c/pca9685.c | 9 +++++----
sys/dev/i2c/pcf8563.c | 11 ++++++-----
sys/dev/i2c/pcf8574.c | 9 +++++----
sys/dev/i2c/spdmem_i2c.c | 11 ++++++-----
sys/dev/i2c/ssdfb_i2c.c | 11 ++++++-----
sys/dev/i2c/sy8106a.c | 9 +++++----
sys/dev/i2c/tcagpio.c | 9 +++++----
sys/dev/i2c/tcakp.c | 9 +++++----
sys/dev/i2c/tda19988.c | 9 +++++----
sys/dev/i2c/titemp.c | 9 +++++----
sys/dev/i2c/tps65217pmic.c | 9 +++++----
sys/dev/i2c/tsllux.c | 11 ++++++-----
sys/dev/i2c/twl4030.c | 9 +++++----
sys/dev/spi/m25p.c | 9 +++++----
sys/dev/spi/oj6sh.c | 9 +++++----
sys/dev/spi/ssdfb_spi.c | 9 +++++----
36 files changed, 193 insertions(+), 158 deletions(-)
diffs (truncated from 1103 to 300 lines):
diff -r c458488c1bdf -r ed3875008341 sys/dev/i2c/ac100.c
--- a/sys/dev/i2c/ac100.c Sun Jan 17 21:19:06 2021 +0000
+++ b/sys/dev/i2c/ac100.c Sun Jan 17 21:42:35 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ac100.c,v 1.4 2019/07/27 16:02:27 thorpej Exp $ */
+/* $NetBSD: ac100.c,v 1.5 2021/01/17 21:42:35 thorpej Exp $ */
/*-
* Copyright (c) 2014 Jared D. McNeill <jmcneill%invisible.ca@localhost>
@@ -29,7 +29,7 @@
#include "opt_fdt.h"
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ac100.c,v 1.4 2019/07/27 16:02:27 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ac100.c,v 1.5 2021/01/17 21:42:35 thorpej Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -93,8 +93,9 @@
#define AC100_RTC_UPD_TRIG_WRITE __BIT(15)
static const struct device_compatible_entry compat_data[] = {
- { "x-powers,ac100", 0 },
- { NULL, 0 }
+ { .compat = "x-powers,ac100" },
+
+ { 0 }
};
struct ac100_softc {
diff -r c458488c1bdf -r ed3875008341 sys/dev/i2c/adadc.c
--- a/sys/dev/i2c/adadc.c Sun Jan 17 21:19:06 2021 +0000
+++ b/sys/dev/i2c/adadc.c Sun Jan 17 21:42:35 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: adadc.c,v 1.7 2019/06/15 02:00:21 macallan Exp $ */
+/* $NetBSD: adadc.c,v 1.8 2021/01/17 21:42:35 thorpej Exp $ */
/*-
* Copyright (c) 2018 Michael Lorenz
@@ -34,7 +34,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: adadc.c,v 1.7 2019/06/15 02:00:21 macallan Exp $");
+__KERNEL_RCSID(0, "$NetBSD: adadc.c,v 1.8 2021/01/17 21:42:35 thorpej Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -94,8 +94,9 @@
adadc_match, adadc_attach, NULL, NULL);
static const struct device_compatible_entry compat_data[] = {
- { "ad7417", 0 },
- { NULL, 0 }
+ { .compat = "ad7417" },
+
+ { 0 }
};
/* calibaration table from Darwin via Linux */
diff -r c458488c1bdf -r ed3875008341 sys/dev/i2c/adm1021.c
--- a/sys/dev/i2c/adm1021.c Sun Jan 17 21:19:06 2021 +0000
+++ b/sys/dev/i2c/adm1021.c Sun Jan 17 21:42:35 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: adm1021.c,v 1.21 2020/12/10 17:02:51 jdc Exp $ */
+/* $NetBSD: adm1021.c,v 1.22 2021/01/17 21:42:35 thorpej Exp $ */
/* $OpenBSD: adm1021.c,v 1.27 2007/06/24 05:34:35 dlg Exp $ */
/*
@@ -38,7 +38,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: adm1021.c,v 1.21 2020/12/10 17:02:51 jdc Exp $");
+__KERNEL_RCSID(0, "$NetBSD: adm1021.c,v 1.22 2021/01/17 21:42:35 thorpej Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -145,10 +145,11 @@
/* XXX: add flags for compats to admtemp_setflags() */
static const struct device_compatible_entry compat_data[] = {
- { "i2c-max1617", 0 },
- { "max6642", 0 },
- { "max6690", 0 },
- { NULL, 0 }
+ { .compat = "i2c-max1617" },
+ { .compat = "max6642" },
+ { .compat = "max6690" },
+
+ { 0 }
};
int
diff -r c458488c1bdf -r ed3875008341 sys/dev/i2c/adm1026.c
--- a/sys/dev/i2c/adm1026.c Sun Jan 17 21:19:06 2021 +0000
+++ b/sys/dev/i2c/adm1026.c Sun Jan 17 21:42:35 2021 +0000
@@ -28,7 +28,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: adm1026.c,v 1.8 2020/06/26 10:06:57 martin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: adm1026.c,v 1.9 2021/01/17 21:42:35 thorpej Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -129,8 +129,9 @@
adm1026_match, adm1026_attach, adm1026_detach, NULL);
static const struct device_compatible_entry compat_data[] = {
- { "i2c-adm1026", 0 },
- { NULL, 0 }
+ { .compat = "i2c-adm1026" },
+
+ { 0 }
};
static int
diff -r c458488c1bdf -r ed3875008341 sys/dev/i2c/anxedp.c
--- a/sys/dev/i2c/anxedp.c Sun Jan 17 21:19:06 2021 +0000
+++ b/sys/dev/i2c/anxedp.c Sun Jan 17 21:42:35 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: anxedp.c,v 1.3 2020/01/01 18:09:44 thorpej Exp $ */
+/* $NetBSD: anxedp.c,v 1.4 2021/01/17 21:42:35 thorpej Exp $ */
/*-
* Copyright (c) 2019 Jared D. McNeill <jmcneill%invisible.ca@localhost>
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: anxedp.c,v 1.3 2020/01/01 18:09:44 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: anxedp.c,v 1.4 2021/01/17 21:42:35 thorpej Exp $");
#include <sys/param.h>
#include <sys/bus.h>
@@ -68,8 +68,9 @@
#define ANX_RPLY_RECEIV __BIT(1)
static const struct device_compatible_entry compat_data[] = {
- { "analogix,anx6345", 1 },
- { NULL }
+ { .compat = "analogix,anx6345" },
+
+ { 0 }
};
struct anxedp_softc;
diff -r c458488c1bdf -r ed3875008341 sys/dev/i2c/as3722.c
--- a/sys/dev/i2c/as3722.c Sun Jan 17 21:19:06 2021 +0000
+++ b/sys/dev/i2c/as3722.c Sun Jan 17 21:42:35 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: as3722.c,v 1.19 2020/01/04 02:21:15 thorpej Exp $ */
+/* $NetBSD: as3722.c,v 1.20 2021/01/17 21:42:35 thorpej Exp $ */
/*-
* Copyright (c) 2015 Jared D. McNeill <jmcneill%invisible.ca@localhost>
@@ -29,7 +29,7 @@
#include "opt_fdt.h"
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: as3722.c,v 1.19 2020/01/04 02:21:15 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: as3722.c,v 1.20 2021/01/17 21:42:35 thorpej Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -223,8 +223,9 @@
#endif
static const struct device_compatible_entry compat_data[] = {
- { "ams,as3722", 0 },
- { NULL, 0 }
+ { .compat = "ams,as3722" },
+
+ { 0 }
};
static int
diff -r c458488c1bdf -r ed3875008341 sys/dev/i2c/asms.c
--- a/sys/dev/i2c/asms.c Sun Jan 17 21:19:06 2021 +0000
+++ b/sys/dev/i2c/asms.c Sun Jan 17 21:42:35 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: asms.c,v 1.1 2020/04/24 12:38:31 macallan Exp $ */
+/* $NetBSD: asms.c,v 1.2 2021/01/17 21:42:35 thorpej Exp $ */
/*-
* Copyright (c) 2020 Michael Lorenz
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: asms.c,v 1.1 2020/04/24 12:38:31 macallan Exp $");
+__KERNEL_RCSID(0, "$NetBSD: asms.c,v 1.2 2021/01/17 21:42:35 thorpej Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -58,9 +58,10 @@
asms_match, asms_attach, NULL, NULL);
static const struct device_compatible_entry compat_data[] = {
- { "accelerometer", 0 },
- { "AAPL,accelerometer_1", 0 },
- { NULL, 0 }
+ { .compat = "accelerometer" },
+ { .compat = "AAPL,accelerometer_1" },
+
+ { 0 }
};
/* ASMS Registers, from OpenBSD */
diff -r c458488c1bdf -r ed3875008341 sys/dev/i2c/axp20x.c
--- a/sys/dev/i2c/axp20x.c Sun Jan 17 21:19:06 2021 +0000
+++ b/sys/dev/i2c/axp20x.c Sun Jan 17 21:42:35 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: axp20x.c,v 1.16 2020/02/16 22:43:27 thorpej Exp $ */
+/* $NetBSD: axp20x.c,v 1.17 2021/01/17 21:42:35 thorpej Exp $ */
/*-
* Copyright (c) 2014-2017 Jared McNeill <jmcneill%invisible.ca@localhost>
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: axp20x.c,v 1.16 2020/02/16 22:43:27 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: axp20x.c,v 1.17 2021/01/17 21:42:35 thorpej Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -211,8 +211,9 @@
axp20x_match, axp20x_attach, NULL, NULL);
static const struct device_compatible_entry compat_data[] = {
- { "x-powers,axp209", 0 },
- { NULL, 0 }
+ { .compat = "x-powers,axp209" },
+
+ { 0 }
};
static int
diff -r c458488c1bdf -r ed3875008341 sys/dev/i2c/axp22x.c
--- a/sys/dev/i2c/axp22x.c Sun Jan 17 21:19:06 2021 +0000
+++ b/sys/dev/i2c/axp22x.c Sun Jan 17 21:42:35 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: axp22x.c,v 1.6 2018/06/26 06:03:57 thorpej Exp $ */
+/* $NetBSD: axp22x.c,v 1.7 2021/01/17 21:42:35 thorpej Exp $ */
/*-
* Copyright (c) 2014 Jared D. McNeill <jmcneill%invisible.ca@localhost>
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: axp22x.c,v 1.6 2018/06/26 06:03:57 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: axp22x.c,v 1.7 2021/01/17 21:42:35 thorpej Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -41,8 +41,9 @@
#include <dev/sysmon/sysmonvar.h>
static const struct device_compatible_entry compat_data[] = {
- { "x-powers,axp221", 0 },
- { NULL, 0 }
+ { .compat = "x-powers,axp221" },
+
+ { 0 }
};
#define AXP_TEMP_MON_REG 0x56 /* 2 bytes */
diff -r c458488c1bdf -r ed3875008341 sys/dev/i2c/cwfg.c
--- a/sys/dev/i2c/cwfg.c Sun Jan 17 21:19:06 2021 +0000
+++ b/sys/dev/i2c/cwfg.c Sun Jan 17 21:42:35 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cwfg.c,v 1.1 2020/01/03 18:00:05 jmcneill Exp $ */
+/* $NetBSD: cwfg.c,v 1.2 2021/01/17 21:42:35 thorpej Exp $ */
/*-
* Copyright (c) 2020 Jared McNeill <jmcneill%invisible.ca@localhost>
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cwfg.c,v 1.1 2020/01/03 18:00:05 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cwfg.c,v 1.2 2021/01/17 21:42:35 thorpej Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -102,8 +102,9 @@
#define CWFG_ALERT_LEVEL_DEFAULT 0
static const struct device_compatible_entry compat_data[] = {
- { "cellwise,cw201x", 1 },
- { NULL, 0 }
+ { .compat = "cellwise,cw201x" },
+
+ { 0 }
};
static int
Home |
Main Index |
Thread Index |
Old Index