On Saturday 12 January 2008, Borislav Petkov wrote:
[...]
> > > set_disk_ro(floppy->disk, floppy->wp);
> > > - page = (idefloppy_flexible_disk_page_t *) (header + 1);
> > > -
> > > - page->transfer_rate = be16_to_cpu(page->transfer_rate);
> > > - page->sector_size = be16_to_cpu(page->sector_siz
[...]
> This is not an equivalent transformation:
>
> header->wp is 0 or 1
> pc.buffer[3] & 0x80 is 0 or 0x80
>
> It seems to work fine for ->wp (because it is needlessly defined as 'int')
> but may seriously confuse set_disk_ro() and thus bdev_read_only() users.
>
> Should be fixed to '(pc.bu
On Saturday 12 January 2008, Bartlomiej Zolnierkiewicz wrote:
[...]
> > - header = (idefloppy_mode_parameter_header_t *) pc.buffer;
> > - floppy->wp = header->wp;
> > + floppy->wp = pc.buffer[3] & 0x80;
>
> This is not an equivalent transformation:
>
> header->wp is 0 or 1
> pc.buffer[3]
On Friday 11 January 2008, Borislav Petkov wrote:
> The driver used to test whether the flexible disk page has changed by
> memcmp-ing
> it with a cached copy of a previous version of the page from a different remo-
> vable medium. Since, according to the SFF-8070i spec, the flexible disk page
>
The driver used to test whether the flexible disk page has changed by memcmp-ing
it with a cached copy of a previous version of the page from a different remo-
vable medium. Since, according to the SFF-8070i spec, the flexible disk page
"specifies parameters relating to the currently installed medi