When past cyl 1024 it's ok if CHS is (0xff,0xff,0xff).
It's actually recommended it seems...
This commit is contained in:
parent
34a839537a
commit
ee1cbe818e
@ -35,7 +35,7 @@
|
||||
*
|
||||
* from: @(#)ufs_disksubr.c 7.16 (Berkeley) 5/4/91
|
||||
* from: ufs_disksubr.c,v 1.8 1994/06/07 01:21:39 phk Exp $
|
||||
* $Id: diskslice_machdep.c,v 1.10 1995/04/20 01:21:51 phk Exp $
|
||||
* $Id: diskslice_machdep.c,v 1.11 1995/04/20 06:01:51 phk Exp $
|
||||
*/
|
||||
|
||||
#include <stddef.h>
|
||||
@ -104,7 +104,9 @@ check_part(sname, dp, offset, nsectors, ntracks, mbr_offset )
|
||||
if (ssector < ssector1
|
||||
&& ((chs_ssect == nsectors && dp->dp_shd == ntracks - 1
|
||||
&& chs_scyl == 1023)
|
||||
|| (ssector1 - ssector) % (1024 * secpercyl) == 0)) {
|
||||
|| (ssector1 - ssector) % (1024 * secpercyl) == 0)
|
||||
|| (dp->dp_ssect == 255 && dp->dp_shd == 255 &&
|
||||
dp->dp_scyl == 255)) {
|
||||
TRACE(("%s: C/H/S start %d/%d/%d, start %lu: allow\n",
|
||||
sname, chs_scyl, dp->dp_shd, chs_ssect, ssector1));
|
||||
ssector = ssector1;
|
||||
@ -120,7 +122,9 @@ check_part(sname, dp, offset, nsectors, ntracks, mbr_offset )
|
||||
if (esector < esector1
|
||||
&& ((chs_esect == nsectors && dp->dp_ehd == ntracks - 1
|
||||
&& chs_ecyl == 1023)
|
||||
|| (esector1 - esector) % (1024 * secpercyl) == 0)) {
|
||||
|| (esector1 - esector) % (1024 * secpercyl) == 0)
|
||||
|| (dp->dp_esect == 255 && dp->dp_ehd == 255 &&
|
||||
dp->dp_ecyl == 255)) {
|
||||
TRACE(("%s: C/H/S end %d/%d/%d, end %lu: allow\n",
|
||||
sname, chs_ecyl, dp->dp_ehd, chs_esect, esector1));
|
||||
esector = esector1;
|
||||
|
@ -35,7 +35,7 @@
|
||||
*
|
||||
* from: @(#)ufs_disksubr.c 7.16 (Berkeley) 5/4/91
|
||||
* from: ufs_disksubr.c,v 1.8 1994/06/07 01:21:39 phk Exp $
|
||||
* $Id: diskslice_machdep.c,v 1.10 1995/04/20 01:21:51 phk Exp $
|
||||
* $Id: diskslice_machdep.c,v 1.11 1995/04/20 06:01:51 phk Exp $
|
||||
*/
|
||||
|
||||
#include <stddef.h>
|
||||
@ -104,7 +104,9 @@ check_part(sname, dp, offset, nsectors, ntracks, mbr_offset )
|
||||
if (ssector < ssector1
|
||||
&& ((chs_ssect == nsectors && dp->dp_shd == ntracks - 1
|
||||
&& chs_scyl == 1023)
|
||||
|| (ssector1 - ssector) % (1024 * secpercyl) == 0)) {
|
||||
|| (ssector1 - ssector) % (1024 * secpercyl) == 0)
|
||||
|| (dp->dp_ssect == 255 && dp->dp_shd == 255 &&
|
||||
dp->dp_scyl == 255)) {
|
||||
TRACE(("%s: C/H/S start %d/%d/%d, start %lu: allow\n",
|
||||
sname, chs_scyl, dp->dp_shd, chs_ssect, ssector1));
|
||||
ssector = ssector1;
|
||||
@ -120,7 +122,9 @@ check_part(sname, dp, offset, nsectors, ntracks, mbr_offset )
|
||||
if (esector < esector1
|
||||
&& ((chs_esect == nsectors && dp->dp_ehd == ntracks - 1
|
||||
&& chs_ecyl == 1023)
|
||||
|| (esector1 - esector) % (1024 * secpercyl) == 0)) {
|
||||
|| (esector1 - esector) % (1024 * secpercyl) == 0)
|
||||
|| (dp->dp_esect == 255 && dp->dp_ehd == 255 &&
|
||||
dp->dp_ecyl == 255)) {
|
||||
TRACE(("%s: C/H/S end %d/%d/%d, end %lu: allow\n",
|
||||
sname, chs_ecyl, dp->dp_ehd, chs_esect, esector1));
|
||||
esector = esector1;
|
||||
|
Loading…
Reference in New Issue
Block a user