Lines Matching refs:ubh
22 struct ufs_buffer_head * ubh; in _ubh_bread_() local
30 ubh = kmalloc (sizeof (struct ufs_buffer_head), GFP_NOFS); in _ubh_bread_()
31 if (!ubh) in _ubh_bread_()
33 ubh->fragment = fragment; in _ubh_bread_()
34 ubh->count = count; in _ubh_bread_()
36 if (!(ubh->bh[i] = sb_bread(sb, fragment + i))) in _ubh_bread_()
39 ubh->bh[i] = NULL; in _ubh_bread_()
40 return ubh; in _ubh_bread_()
43 brelse (ubh->bh[j]); in _ubh_bread_()
44 kfree(ubh); in _ubh_bread_()
72 void ubh_brelse (struct ufs_buffer_head * ubh) in ubh_brelse() argument
75 if (!ubh) in ubh_brelse()
77 for (i = 0; i < ubh->count; i++) in ubh_brelse()
78 brelse (ubh->bh[i]); in ubh_brelse()
79 kfree (ubh); in ubh_brelse()
93 void ubh_mark_buffer_dirty (struct ufs_buffer_head * ubh) in ubh_mark_buffer_dirty() argument
96 if (!ubh) in ubh_mark_buffer_dirty()
98 for ( i = 0; i < ubh->count; i++ ) in ubh_mark_buffer_dirty()
99 mark_buffer_dirty (ubh->bh[i]); in ubh_mark_buffer_dirty()
102 void ubh_mark_buffer_uptodate (struct ufs_buffer_head * ubh, int flag) in ubh_mark_buffer_uptodate() argument
105 if (!ubh) in ubh_mark_buffer_uptodate()
108 for ( i = 0; i < ubh->count; i++ ) in ubh_mark_buffer_uptodate()
109 set_buffer_uptodate (ubh->bh[i]); in ubh_mark_buffer_uptodate()
111 for ( i = 0; i < ubh->count; i++ ) in ubh_mark_buffer_uptodate()
112 clear_buffer_uptodate (ubh->bh[i]); in ubh_mark_buffer_uptodate()
116 void ubh_sync_block(struct ufs_buffer_head *ubh) in ubh_sync_block() argument
118 if (ubh) { in ubh_sync_block()
121 for (i = 0; i < ubh->count; i++) in ubh_sync_block()
122 write_dirty_buffer(ubh->bh[i], 0); in ubh_sync_block()
124 for (i = 0; i < ubh->count; i++) in ubh_sync_block()
125 wait_on_buffer(ubh->bh[i]); in ubh_sync_block()
129 void ubh_bforget (struct ufs_buffer_head * ubh) in ubh_bforget() argument
132 if (!ubh) in ubh_bforget()
134 for ( i = 0; i < ubh->count; i++ ) if ( ubh->bh[i] ) in ubh_bforget()
135 bforget (ubh->bh[i]); in ubh_bforget()
138 int ubh_buffer_dirty (struct ufs_buffer_head * ubh) in ubh_buffer_dirty() argument
142 if (!ubh) in ubh_buffer_dirty()
144 for ( i = 0; i < ubh->count; i++ ) in ubh_buffer_dirty()
145 result |= buffer_dirty(ubh->bh[i]); in ubh_buffer_dirty()
150 unsigned char * mem, struct ufs_buffer_head * ubh, unsigned size) in _ubh_ubhcpymem_() argument
153 if (size > (ubh->count << uspi->s_fshift)) in _ubh_ubhcpymem_()
154 size = ubh->count << uspi->s_fshift; in _ubh_ubhcpymem_()
158 memcpy (mem, ubh->bh[bhno]->b_data, len); in _ubh_ubhcpymem_()
166 struct ufs_buffer_head * ubh, unsigned char * mem, unsigned size) in _ubh_memcpyubh_() argument
169 if (size > (ubh->count << uspi->s_fshift)) in _ubh_memcpyubh_()
170 size = ubh->count << uspi->s_fshift; in _ubh_memcpyubh_()
174 memcpy (ubh->bh[bhno]->b_data, mem, len); in _ubh_memcpyubh_()