devio: change meaning of return from bfree
authorAlan Cox <alan@linux.intel.com>
Sun, 12 Nov 2017 21:31:55 +0000 (21:31 +0000)
committerAlan Cox <alan@linux.intel.com>
Sun, 12 Nov 2017 21:31:55 +0000 (21:31 +0000)
We need this to keep inode.c sane. As nobody else uses the return code
this *should* be fine.

Kernel/devio.c

index 2447606..ebf9437 100644 (file)
@@ -93,10 +93,12 @@ int bfree(bufptr bp, uint8_t dirty)
                bp->bf_busy = BF_FREE;
 
        if (dirty > 1) {        /* immediate writeback */
-               if (bdwrite(bp) != BLKSIZE)
+               if (bdwrite(bp) != BLKSIZE) {
                        udata.u_error = EIO;
+                       return -1;
+               }
                bp->bf_dirty = false;
-               return -1;
+               return 0;
        }
        return 0;
 }