Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch Use b_cylinder as defined in sys/buf.h
details: https://anonhg.NetBSD.org/src/rev/cc4b3c7ca362
branches: trunk
changeset: 480711:cc4b3c7ca362
user: thorpej <thorpej%NetBSD.org@localhost>
date: Tue Jan 18 19:34:24 2000 +0000
description:
Use b_cylinder as defined in sys/buf.h
diffstat:
sys/arch/alpha/alpha/disksubr.c | 12 +++++-------
sys/arch/amiga/amiga/disksubr.c | 9 ++++-----
sys/arch/arm32/arm32/disksubr.c | 12 +++++-------
sys/arch/arm32/arm32/disksubr_acorn.c | 10 ++++------
sys/arch/arm32/arm32/disksubr_mbr.c | 8 +++-----
5 files changed, 21 insertions(+), 30 deletions(-)
diffs (233 lines):
diff -r 750b286dcdd0 -r cc4b3c7ca362 sys/arch/alpha/alpha/disksubr.c
--- a/sys/arch/alpha/alpha/disksubr.c Tue Jan 18 19:33:31 2000 +0000
+++ b/sys/arch/alpha/alpha/disksubr.c Tue Jan 18 19:34:24 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: disksubr.c,v 1.16 1998/10/15 19:08:33 drochner Exp $ */
+/* $NetBSD: disksubr.c,v 1.17 2000/01/18 19:34:24 thorpej Exp $ */
/*
* Copyright (c) 1994, 1995, 1996 Carnegie-Mellon University.
@@ -29,7 +29,7 @@
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
-__KERNEL_RCSID(0, "$NetBSD: disksubr.c,v 1.16 1998/10/15 19:08:33 drochner Exp $");
+__KERNEL_RCSID(0, "$NetBSD: disksubr.c,v 1.17 2000/01/18 19:34:24 thorpej Exp $");
#include <sys/param.h>
#include <sys/buf.h>
@@ -47,8 +47,6 @@
extern struct device *bootdv;
-#define b_cylin b_resid /* XXX */
-
/* was this the boot device ? */
void
dk_establish(dk, dev)
@@ -95,7 +93,7 @@
/* next, dig out disk label */
bp->b_dev = dev;
bp->b_blkno = LABELSECTOR;
- bp->b_cylin = 0;
+ bp->b_cylinder = 0;
bp->b_bcount = lp->d_secsize;
bp->b_flags = B_BUSY | B_READ;
(*strat)(bp);
@@ -131,7 +129,7 @@
else
bp->b_blkno /= DEV_BSIZE / lp->d_secsize;
bp->b_bcount = lp->d_secsize;
- bp->b_cylin = lp->d_ncylinders - 1;
+ bp->b_cylinder = lp->d_ncylinders - 1;
(*strat)(bp);
/* if successful, validate, otherwise try another */
@@ -233,7 +231,7 @@
bp = geteblk((int)lp->d_secsize);
bp->b_dev = dev;
bp->b_blkno = LABELSECTOR;
- bp->b_cylin = 0;
+ bp->b_cylinder = 0;
bp->b_bcount = lp->d_secsize;
bp->b_flags = B_READ; /* get current label */
(*strat)(bp);
diff -r 750b286dcdd0 -r cc4b3c7ca362 sys/arch/amiga/amiga/disksubr.c
--- a/sys/arch/amiga/amiga/disksubr.c Tue Jan 18 19:33:31 2000 +0000
+++ b/sys/arch/amiga/amiga/disksubr.c Tue Jan 18 19:34:24 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: disksubr.c,v 1.31 1999/06/02 21:09:03 is Exp $ */
+/* $NetBSD: disksubr.c,v 1.32 2000/01/18 19:35:13 thorpej Exp $ */
/*
* Copyright (c) 1994 Christian E. Hopps
@@ -79,7 +79,6 @@
} tab[0];
};
-#define b_cylin b_resid
#define baddr(bp) (void *)((bp)->b_un.b_addr)
u_long rdbchksum __P((void *));
@@ -162,7 +161,7 @@
*/
for (nextb = 0; nextb < RDB_MAXBLOCKS; nextb++) {
bp->b_blkno = nextb;
- bp->b_cylin = bp->b_blkno / lp->d_secpercyl;
+ bp->b_cylinder = bp->b_blkno / lp->d_secpercyl;
bp->b_bcount = lp->d_secsize;
bp->b_flags = B_BUSY | B_READ;
#ifdef SD_C_ADJUSTS_NR
@@ -256,7 +255,7 @@
cindex = 0;
for (nextb = rbp->partbhead; nextb != RDBNULL; nextb = pbp->next) {
bp->b_blkno = nextb;
- bp->b_cylin = bp->b_blkno / lp->d_secpercyl;
+ bp->b_cylinder = bp->b_blkno / lp->d_secpercyl;
bp->b_bcount = lp->d_secsize;
bp->b_flags = B_BUSY | B_READ;
#ifdef SD_C_ADJUSTS_NR
@@ -561,7 +560,7 @@
/*
* calc cylinder for disksort to order transfers with
*/
- bp->b_cylin = (bp->b_blkno + pp->p_offset) / lp->d_secpercyl;
+ bp->b_cylinder = (bp->b_blkno + pp->p_offset) / lp->d_secpercyl;
return(1);
}
diff -r 750b286dcdd0 -r cc4b3c7ca362 sys/arch/arm32/arm32/disksubr.c
--- a/sys/arch/arm32/arm32/disksubr.c Tue Jan 18 19:33:31 2000 +0000
+++ b/sys/arch/arm32/arm32/disksubr.c Tue Jan 18 19:34:24 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: disksubr.c,v 1.11 1998/06/08 20:21:17 mark Exp $ */
+/* $NetBSD: disksubr.c,v 1.12 2000/01/18 19:36:24 thorpej Exp $ */
/*
* Copyright (c) 1998 Christopher G. Demetriou. All rights reserved.
@@ -75,8 +75,6 @@
#include <sys/device.h>
#include <sys/disk.h>
-#define b_cylin b_resid
-
/*
* Attempt to read a disk label from a device
* using the indicated stategy routine.
@@ -164,7 +162,7 @@
/* printf("Reading disklabel addr=%08x\n", netbsdpartoff * DEV_BSIZE);*/
bp->b_blkno = netbsdpartoff + LABELSECTOR;
- bp->b_cylin = bp->b_blkno / lp->d_secpercyl;
+ bp->b_cylinder = bp->b_blkno / lp->d_secpercyl;
bp->b_bcount = lp->d_secsize;
bp->b_flags = B_BUSY | B_READ;
(*strat)(bp);
@@ -209,7 +207,7 @@
else
bp->b_blkno /= DEV_BSIZE / lp->d_secsize;
bp->b_bcount = lp->d_secsize;
- bp->b_cylin = lp->d_ncylinders - 1;
+ bp->b_cylinder = lp->d_ncylinders - 1;
(*strat)(bp);
/* if successful, validate, otherwise try another */
@@ -352,7 +350,7 @@
/* next, dig out disk label */
bp->b_blkno = netbsdpartoff + LABELSECTOR;
- bp->b_cylin = cyl;
+ bp->b_cylinder = cyl;
bp->b_bcount = lp->d_secsize;
bp->b_flags = B_BUSY | B_READ;
(*strat)(bp);
@@ -427,7 +425,7 @@
}
/* calculate cylinder for disksort to order transfers with */
- bp->b_cylin = (bp->b_blkno + p->p_offset) /
+ bp->b_cylinder = (bp->b_blkno + p->p_offset) /
(lp->d_secsize / DEV_BSIZE) / lp->d_secpercyl;
return (1);
diff -r 750b286dcdd0 -r cc4b3c7ca362 sys/arch/arm32/arm32/disksubr_acorn.c
--- a/sys/arch/arm32/arm32/disksubr_acorn.c Tue Jan 18 19:33:31 2000 +0000
+++ b/sys/arch/arm32/arm32/disksubr_acorn.c Tue Jan 18 19:34:24 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: disksubr_acorn.c,v 1.2 1998/10/06 01:47:53 mark Exp $ */
+/* $NetBSD: disksubr_acorn.c,v 1.3 2000/01/18 19:36:24 thorpej Exp $ */
/*
* Copyright (c) 1998 Christopher G. Demetriou. All rights reserved.
@@ -71,8 +71,6 @@
#include <sys/buf.h>
#include <sys/disklabel.h>
-#define b_cylin b_resid
-
/*
* static int filecore_checksum(u_char *bootblock)
*
@@ -172,7 +170,7 @@
bp->b_blkno = FILECORE_BOOT_SECTOR;
bp->b_bcount = lp->d_secsize;
bp->b_flags = B_BUSY | B_READ;
- bp->b_cylin = bp->b_blkno / lp->d_secpercyl;
+ bp->b_cylinder = bp->b_blkno / lp->d_secpercyl;
(*strat)(bp);
/*
@@ -224,7 +222,7 @@
bp->b_blkno = cyl * heads * sectors;
/* printf("Found RiscIX partition table @ %08x\n",
bp->b_blkno);*/
- bp->b_cylin = bp->b_blkno / lp->d_secpercyl;
+ bp->b_cylinder = bp->b_blkno / lp->d_secpercyl;
bp->b_bcount = lp->d_secsize;
bp->b_flags = B_BUSY | B_READ;
(*strat)(bp);
@@ -304,7 +302,7 @@
bp->b_blkno = FILECORE_BOOT_SECTOR;
bp->b_bcount = lp->d_secsize;
bp->b_flags = B_BUSY | B_READ;
- bp->b_cylin = bp->b_blkno / lp->d_secpercyl;
+ bp->b_cylinder = bp->b_blkno / lp->d_secpercyl;
(*strat)(bp);
/*
diff -r 750b286dcdd0 -r cc4b3c7ca362 sys/arch/arm32/arm32/disksubr_mbr.c
--- a/sys/arch/arm32/arm32/disksubr_mbr.c Tue Jan 18 19:33:31 2000 +0000
+++ b/sys/arch/arm32/arm32/disksubr_mbr.c Tue Jan 18 19:34:24 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: disksubr_mbr.c,v 1.3 1999/01/29 21:20:22 matthias Exp $ */
+/* $NetBSD: disksubr_mbr.c,v 1.4 2000/01/18 19:36:24 thorpej Exp $ */
/*
* Copyright (c) 1998 Christopher G. Demetriou. All rights reserved.
@@ -78,8 +78,6 @@
#include "opt_mbr.h"
-#define b_cylin b_resid
-
#define MBRSIGOFS 0x1fe
static char mbrsig[2] = {0x55, 0xaa};
@@ -119,7 +117,7 @@
bp->b_blkno = MBR_BBSECTOR;
bp->b_bcount = lp->d_secsize;
bp->b_flags = B_BUSY | B_READ;
- bp->b_cylin = MBR_BBSECTOR / lp->d_secpercyl;
+ bp->b_cylinder = MBR_BBSECTOR / lp->d_secpercyl;
(*strat)(bp);
/* if successful, wander through dos partition table */
@@ -231,7 +229,7 @@
bp->b_blkno = MBR_BBSECTOR;
bp->b_bcount = lp->d_secsize;
bp->b_flags = B_BUSY | B_READ;
- bp->b_cylin = MBR_BBSECTOR / lp->d_secpercyl;
+ bp->b_cylinder = MBR_BBSECTOR / lp->d_secpercyl;
(*strat)(bp);
if ((rv = biowait(bp)) != 0) {
Home |
Main Index |
Thread Index |
Old Index