D | badblocks.c | 367 static int do_read (int dev, unsigned char * buffer, int try, int block_size, in do_read() argument 376 printf("do_read: block %d, try %d\n", current_block, try); in do_read() 378 set_o_direct(dev, buffer, try * block_size, in do_read() 392 got = read (dev, buffer, try * block_size); in do_read() 400 if (d_flag && got == try) { in do_read() 443 static int do_write(int dev, unsigned char * buffer, int try, int block_size, in do_write() argument 449 printf("do_write: block %lu, try %d\n", current_block, try); in do_write() 451 set_o_direct(dev, buffer, try * block_size, in do_write() 463 got = write (dev, buffer, try * block_size); in do_write() 493 int try; in test_ro() local [all …]
|