Lines Matching defs:bs
1086 off_t bs = m_maxbcachebuf;
1087 ssize_t fsize = 3 * bs;
1090 readbuf = malloc(bs);
1092 zeros = calloc(1, 3 * bs);
1094 ones = calloc(1, 2 * bs);
1096 memset(ones, 1, 2 * bs);
1097 zeroones = calloc(1, bs);
1099 memset((uint8_t*)zeroones + bs / 2, 1, bs / 2);
1100 onezeros = calloc(1, bs);
1102 memset(onezeros, 1, bs / 2);
1111 ASSERT_EQ(3 * bs, pwrite(fd, zeros, 3 * bs, 0)) << strerror(errno);
1117 FuseTest::expect_write(ino, 0, bs, bs, 0, 0, zeros);
1118 FuseTest::expect_write(ino, 2 * bs, bs, bs, 0, 0, zeros);
1120 FuseTest::expect_write(ino, bs / 2, bs, bs, 0, 0, ones);
1121 FuseTest::expect_write(ino, 3 * bs / 2, bs, bs, 0, 0, ones);
1123 ASSERT_EQ(2 * bs, pwrite(fd, ones, 2 * bs, bs / 2)) << strerror(errno);
1130 expect_read(ino, 0, bs, bs, zeroones);
1131 expect_read(ino, 2 * bs, bs, bs, onezeros);
1133 ASSERT_EQ(bs / 2, pread(fd, readbuf, bs / 2, 0)) << strerror(errno);
1134 EXPECT_EQ(0, memcmp(zeros, readbuf, bs / 2));
1135 ASSERT_EQ(bs / 2, pread(fd, readbuf, bs / 2, 5 * bs / 2))
1137 EXPECT_EQ(0, memcmp(zeros, readbuf, bs / 2));
1138 ASSERT_EQ(bs / 2, pread(fd, readbuf, bs / 2, bs / 2))
1140 EXPECT_EQ(0, memcmp(ones, readbuf, bs / 2));
1141 ASSERT_EQ(bs / 2, pread(fd, readbuf, bs / 2, 2 * bs))
1143 EXPECT_EQ(0, memcmp(ones, readbuf, bs / 2));