Set si_bsize_phys and si_bsize_max in all legacy CD drivers.
This commit is contained in:
parent
c6b85633cb
commit
db6f05bfac
@ -296,6 +296,8 @@ int mcdopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
if (!(cd->flags & MCDVALID) && cd->openflags)
|
||||
return ENXIO;
|
||||
|
||||
dev->si_bsize_phys = 2048;
|
||||
dev->si_bsize_max = MAXBSIZE;
|
||||
if (mcd_getstat(unit,1) == -1)
|
||||
return EIO;
|
||||
|
||||
|
@ -258,6 +258,8 @@ scdopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
|
||||
XDEBUG(1,("scd%d: DEBUG: status = 0x%x\n", unit, inb(cd->iobase+IREG_STATUS)));
|
||||
|
||||
dev->si_bsize_phys = 2048;
|
||||
dev->si_bsize_max = MAXBSIZE;
|
||||
if ((rc = spin_up(unit)) != 0) {
|
||||
print_error(unit, rc);
|
||||
return EIO;
|
||||
|
@ -399,6 +399,8 @@ acdopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
return ENXIO;
|
||||
cdp = acdtab[lun];
|
||||
|
||||
dev->si_bsize_phys = 2048;
|
||||
dev->si_bsize_max = MAXBSIZE;
|
||||
if (!(cdp->flags & F_BOPEN) && !cdp->refcnt) {
|
||||
/* Prevent user eject */
|
||||
acd_request_wait(cdp, ATAPI_PREVENT_ALLOW,
|
||||
|
@ -623,6 +623,8 @@ int matcdopen(dev_t dev, int flags, int fmt,
|
||||
|
||||
if (ldrive >= TOTALDRIVES) return(ENXIO);
|
||||
|
||||
dev->si_bsize_phys = 2048;
|
||||
dev->si_bsize_max = MAXBSIZE;
|
||||
|
||||
#ifdef DEBUGOPEN
|
||||
printf("matcd%d: Open: dev %x partition %x controller %x flags %x cdrive %x\n",
|
||||
|
@ -296,6 +296,8 @@ int mcdopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
if (!(cd->flags & MCDVALID) && cd->openflags)
|
||||
return ENXIO;
|
||||
|
||||
dev->si_bsize_phys = 2048;
|
||||
dev->si_bsize_max = MAXBSIZE;
|
||||
if (mcd_getstat(unit,1) == -1)
|
||||
return EIO;
|
||||
|
||||
|
@ -258,6 +258,8 @@ scdopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
|
||||
XDEBUG(1,("scd%d: DEBUG: status = 0x%x\n", unit, inb(cd->iobase+IREG_STATUS)));
|
||||
|
||||
dev->si_bsize_phys = 2048;
|
||||
dev->si_bsize_max = MAXBSIZE;
|
||||
if ((rc = spin_up(unit)) != 0) {
|
||||
print_error(unit, rc);
|
||||
return EIO;
|
||||
|
@ -399,6 +399,8 @@ acdopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
return ENXIO;
|
||||
cdp = acdtab[lun];
|
||||
|
||||
dev->si_bsize_phys = 2048;
|
||||
dev->si_bsize_max = MAXBSIZE;
|
||||
if (!(cdp->flags & F_BOPEN) && !cdp->refcnt) {
|
||||
/* Prevent user eject */
|
||||
acd_request_wait(cdp, ATAPI_PREVENT_ALLOW,
|
||||
|
@ -399,6 +399,8 @@ acdopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
return ENXIO;
|
||||
cdp = acdtab[lun];
|
||||
|
||||
dev->si_bsize_phys = 2048;
|
||||
dev->si_bsize_max = MAXBSIZE;
|
||||
if (!(cdp->flags & F_BOPEN) && !cdp->refcnt) {
|
||||
/* Prevent user eject */
|
||||
acd_request_wait(cdp, ATAPI_PREVENT_ALLOW,
|
||||
|
Loading…
Reference in New Issue
Block a user