summaryrefslogtreecommitdiffstats
path: root/sys/i386/bios
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>2003-03-03 12:15:54 +0000
committerphk <phk@FreeBSD.org>2003-03-03 12:15:54 +0000
commit0ae911eb0e57eebb61c50c02ddf69aa67ed19599 (patch)
tree4e91d5779ffebe1d75e975aa4450f35f965430eb /sys/i386/bios
parente58d97a666e757e8429a219da05f88a51554c32c (diff)
downloadFreeBSD-src-0ae911eb0e57eebb61c50c02ddf69aa67ed19599.zip
FreeBSD-src-0ae911eb0e57eebb61c50c02ddf69aa67ed19599.tar.gz
Gigacommit to improve device-driver source compatibility between
branches: Initialize struct cdevsw using C99 sparse initializtion and remove all initializations to default values. This patch is automatically generated and has been tested by compiling LINT with all the fields in struct cdevsw in reverse order on alpha, sparc64 and i386. Approved by: re(scottl)
Diffstat (limited to 'sys/i386/bios')
-rw-r--r--sys/i386/bios/apm.c20
-rw-r--r--sys/i386/bios/smapi.c20
2 files changed, 13 insertions, 27 deletions
diff --git a/sys/i386/bios/apm.c b/sys/i386/bios/apm.c
index 5279873..66bcdbe 100644
--- a/sys/i386/bios/apm.c
+++ b/sys/i386/bios/apm.c
@@ -90,19 +90,13 @@ static d_poll_t apmpoll;
#define CDEV_MAJOR 39
static struct cdevsw apm_cdevsw = {
- /* open */ apmopen,
- /* close */ apmclose,
- /* read */ noread,
- /* write */ apmwrite,
- /* ioctl */ apmioctl,
- /* poll */ apmpoll,
- /* mmap */ nommap,
- /* strategy */ nostrategy,
- /* name */ "apm",
- /* maj */ CDEV_MAJOR,
- /* dump */ nodump,
- /* psize */ nopsize,
- /* flags */ 0,
+ .d_open = apmopen,
+ .d_close = apmclose,
+ .d_write = apmwrite,
+ .d_ioctl = apmioctl,
+ .d_poll = apmpoll,
+ .d_name = "apm",
+ .d_maj = CDEV_MAJOR,
};
static int apm_suspend_delay = 1;
diff --git a/sys/i386/bios/smapi.c b/sys/i386/bios/smapi.c
index 038a076..80b8f4c 100644
--- a/sys/i386/bios/smapi.c
+++ b/sys/i386/bios/smapi.c
@@ -54,20 +54,12 @@ static d_ioctl_t smapi_ioctl;
#define CDEV_MAJOR 183
static struct cdevsw smapi_cdevsw = {
- /* open */ smapi_open,
- /* close */ smapi_close,
- /* read */ noread,
- /* write */ nowrite,
- /* ioctl */ smapi_ioctl,
- /* poll */ nopoll,
- /* mmap */ nommap,
- /* strategy */ nostrategy,
- /* name */ "smapi",
- /* maj */ CDEV_MAJOR,
- /* dump */ nodump,
- /* psize */ nopsize,
- /* flags */ D_MEM,
- /* kqfilter */ NULL,
+ .d_open = smapi_open,
+ .d_close = smapi_close,
+ .d_ioctl = smapi_ioctl,
+ .d_name = "smapi",
+ .d_maj = CDEV_MAJOR,
+ .d_flags = D_MEM,
};
static int
OpenPOWER on IntegriCloud