lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Sun, 5 Nov 2006 12:20:48 +0530
From:	"Palakodeti, Srinivasa Rao (STSD)" <palakodetisrinivasa.rao@...com>
To:	<linux-kernel@...r.kernel.org>
Subject: Need help in writing Layered driver in Linux

Hi All, 

I want to write a layered driver for a device in Linux. I am overwriting
make_request_fn in blk_dev strucure. Whenever they is an I/O my
make_request_fn is called so that I can change the buffer_head and send
to other disk by calling submit_bh in my make_request_fn as following.



		bh->b_dev = MKDEV(252,0); // I am changing to other disk
device
		atomic_set(&bh->b_count, 1);
		submit_bh(WRITE, bh);

This is not working. It is giving me kernel panic Could you help me how
should I go about it? 

My purpose is all I/O to Disk1 should to passed to Disk2. 


Regards,
Srinivas 
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ