File: orig

package info (click to toggle)
wiggle 1.3-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 15,036 kB
  • sloc: ansic: 13,649; sh: 1,180; makefile: 194
file content (15 lines) | stat: -rw-r--r-- 438 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
static struct buffer_head *raid5_build_block (struct stripe_head *sh, int i)
{
	raid5_conf_t *conf = sh->raid_conf;
	struct buffer_head *bh = sh->bh_cache[i];
	unsigned long block = sh->sector / (sh->size >> 9);

	init_buffer(bh, raid5_end_read_request, sh);
	bh->b_dev       = conf->disks[i].dev;
	bh->b_blocknr   = block;

	bh->b_state	= (1 << BH_Req) | (1 << BH_Mapped);
	bh->b_size	= sh->size;
	bh->b_list	= BUF_LOCKED;
	return bh;
}