patch-2.2.15 linux/include/asm-sparc64/floppy.h
Next file: linux/include/asm-sparc64/io.h
Previous file: linux/include/asm-sparc64/ethtool.h
Back to the patch index
Back to the overall index
- Lines: 53
- Date:
Fri Apr 21 12:46:50 2000
- Orig file:
v2.2.14/include/asm-sparc64/floppy.h
- Orig date:
Sat Aug 28 20:00:58 1999
diff -u --new-file --recursive --exclude-from ../../exclude v2.2.14/include/asm-sparc64/floppy.h linux/include/asm-sparc64/floppy.h
@@ -1,4 +1,4 @@
-/* $Id: floppy.h,v 1.18.2.2 1999/08/09 21:07:41 ecd Exp $
+/* $Id: floppy.h,v 1.18.2.4 2000/02/27 04:44:47 davem Exp $
* asm-sparc64/floppy.h: Sparc specific parts of the Floppy driver.
*
* Copyright (C) 1996 David S. Miller (davem@caip.rutgers.edu)
@@ -183,6 +183,8 @@
doing_pdma = 0;
if (pdma_base) {
mmu_unlockarea(pdma_base, pdma_areasize);
+ __flush_dcache_range((unsigned long)pdma_base,
+ (unsigned long)pdma_base + pdma_areasize);
pdma_base = 0;
}
}
@@ -574,7 +576,6 @@
struct linux_ebus_device *edev = 0;
unsigned long config = 0;
unsigned long auxio_reg;
- unsigned char cfg;
for_each_ebus(ebus) {
for_each_ebusdev(edev, ebus) {
@@ -678,9 +679,7 @@
return sun_floppy_types[0];
/* Enable PC-AT mode. */
- cfg = ns87303_readb(config, ASC);
- cfg |= 0xc0;
- ns87303_writeb(config, ASC, cfg);
+ ns87303_modify(config, ASC, 0, 0xc0);
#ifdef PCI_FDC_SWAP_DRIVES
/*
@@ -691,15 +690,9 @@
* Set the drive exchange bit in FCR on NS87303,
* make shure other bits are sane before doing so.
*/
- cfg = ns87303_readb(config, FER);
- cfg &= ~(FER_EDM);
- ns87303_writeb(config, FER, cfg);
- cfg = ns87303_readb(config, ASC);
- cfg &= ~(ASC_DRV2_SEL);
- ns87303_writeb(config, ASC, cfg);
- cfg = ns87303_readb(config, FCR);
- cfg |= FCR_LDE;
- ns87303_writeb(config, FCR, cfg);
+ ns87303_modify(config, FER, FER_EDM, 0);
+ ns87303_modify(config, ASC, ASC_DRV2_SEL, 0);
+ ns87303_modify(config, FCR, 0, FCR_LDE);
cfg = sun_floppy_types[0];
sun_floppy_types[0] = sun_floppy_types[1];
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)