This patch removes the 64-bit divides introduced in the previous patch
in favor of shifting, so that it will compile properly on 32-bit machines.
Signed-off-by: Bob Peterson <rpeterso@redhat.com>
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
return ret;
atomic_set(&ip->i_res->rs_sizehint,
return ret;
atomic_set(&ip->i_res->rs_sizehint,
- PAGE_CACHE_SIZE / sdp->sd_sb.sb_bsize);
+ PAGE_CACHE_SIZE >> sdp->sd_sb.sb_bsize_shift);
gfs2_holder_init(ip->i_gl, LM_ST_EXCLUSIVE, 0, &gh);
ret = gfs2_glock_nq(&gh);
gfs2_holder_init(ip->i_gl, LM_ST_EXCLUSIVE, 0, &gh);
ret = gfs2_glock_nq(&gh);
- atomic_set(&ip->i_res->rs_sizehint, writesize / sdp->sd_sb.sb_bsize);
+ atomic_set(&ip->i_res->rs_sizehint, writesize >> sdp->sd_sb.sb_bsize_shift);
if (file->f_flags & O_APPEND) {
struct gfs2_holder gh;
if (file->f_flags & O_APPEND) {
struct gfs2_holder gh;
if (unlikely(error))
goto out_uninit;
if (unlikely(error))
goto out_uninit;
- atomic_set(&ip->i_res->rs_sizehint, len / sdp->sd_sb.sb_bsize);
+ atomic_set(&ip->i_res->rs_sizehint, len >> sdp->sd_sb.sb_bsize_shift);
while (len > 0) {
if (len < bytes)
while (len > 0) {
if (len < bytes)