More warning fixes; fixed Axel's mess (thanks anyway :)
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6344 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -409,7 +409,7 @@ flo_read(floppy_cookie *cookie, off_t position, void *data, size_t *numbytes)
|
|||||||
size_t toread;
|
size_t toread;
|
||||||
TRACE("read: begin %Ld, %ld\n", position, bytes_read);
|
TRACE("read: begin %Ld, %ld\n", position, bytes_read);
|
||||||
err = read_sectors(cookie->flp, position / sectsize, 1);
|
err = read_sectors(cookie->flp, position / sectsize, 1);
|
||||||
TRACE("PIO READ got %d sect\n", err);
|
TRACE("PIO READ got %ld sect\n", err);
|
||||||
if (err <= 0) {
|
if (err <= 0) {
|
||||||
*numbytes = 0;
|
*numbytes = 0;
|
||||||
return err;
|
return err;
|
||||||
@@ -427,7 +427,7 @@ flo_read(floppy_cookie *cookie, off_t position, void *data, size_t *numbytes)
|
|||||||
|
|
||||||
// try to read as many sectors as we can
|
// try to read as many sectors as we can
|
||||||
err = read_sectors(cookie->flp, position / sectsize, len / sectsize);
|
err = read_sectors(cookie->flp, position / sectsize, len / sectsize);
|
||||||
TRACE("PIO READ got %d sect\n", err);
|
TRACE("PIO READ got %ld sect\n", err);
|
||||||
if (err <= 0) {
|
if (err <= 0) {
|
||||||
*numbytes = 0;
|
*numbytes = 0;
|
||||||
return err;
|
return err;
|
||||||
@@ -442,7 +442,7 @@ flo_read(floppy_cookie *cookie, off_t position, void *data, size_t *numbytes)
|
|||||||
TRACE("read: end %Ld, %ld %ld\n", position, bytes_read, len);
|
TRACE("read: end %Ld, %ld %ld\n", position, bytes_read, len);
|
||||||
|
|
||||||
err = read_sectors(cookie->flp, position / sectsize, 1);
|
err = read_sectors(cookie->flp, position / sectsize, 1);
|
||||||
TRACE("PIO READ got %d sect\n", err);
|
TRACE("PIO READ got %ld sect\n", err);
|
||||||
if (err <= 0) {
|
if (err <= 0) {
|
||||||
*numbytes = 0;
|
*numbytes = 0;
|
||||||
return err;
|
return err;
|
||||||
@@ -473,7 +473,7 @@ flo_control(floppy_cookie *cookie, uint32 op, void *data, size_t len)
|
|||||||
floppy_t *flp = cookie->flp;
|
floppy_t *flp = cookie->flp;
|
||||||
switch (op) {
|
switch (op) {
|
||||||
case B_GET_ICON:
|
case B_GET_ICON:
|
||||||
TRACE("control(B_GET_ICON, %d)\n", ((device_icon *)data)->icon_size);
|
TRACE("control(B_GET_ICON, %ld)\n", ((device_icon *)data)->icon_size);
|
||||||
if (((device_icon *)data)->icon_size == 16) { /* mini icon */
|
if (((device_icon *)data)->icon_size == 16) { /* mini icon */
|
||||||
memcpy(((device_icon *)data)->icon_data, floppy_mini_icon, (16*16));
|
memcpy(((device_icon *)data)->icon_data, floppy_mini_icon, (16*16));
|
||||||
return B_OK;
|
return B_OK;
|
||||||
|
|||||||
@@ -512,7 +512,7 @@ recalibrate_drive(floppy_t *flp)
|
|||||||
TRACE("recalibration failed\n");
|
TRACE("recalibration failed\n");
|
||||||
return 2;
|
return 2;
|
||||||
} if (flp->result[1] != 0) {
|
} if (flp->result[1] != 0) {
|
||||||
TRACE("drive is at cylinder %d, didn't make it to 0\n", result[1]);
|
TRACE("drive is at cylinder %d, didn't make it to 0\n", flp->result[1]);
|
||||||
if (retry > 3)
|
if (retry > 3)
|
||||||
return 1;
|
return 1;
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user