<br><br><div class="gmail_quote">On Wed, Jun 22, 2011 at 5:22 PM, RKK <span dir="ltr"><<a href="mailto:kulkarni.ravi4@gmail.com">kulkarni.ravi4@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
Hi all ,<br>
Im trying to implement a custom new storage protocl which uses SCSI<br>
for storage in Linux . I have been looking around for some files in<br>
the Linux SCSI subsystems to understand its three layered design. The<br>
idea is to develop a separate stack which will internally use SCSI .<br>
so to get started all i want to do is write a module(kernel space)<br>
which sends SCSI commands to target device and retrieve some<br>
information from it. any idea like to how to proceed and which are<br>
files/books that can help me in this regard. I'm reading SCSI SPC-4<br>
and SBC-3 specifications .<br>
<br></blockquote><div>Hi Ravi,<br> Please have a look at files drivers/scsi/scsi_lib.c , drivers/scsi/scsi.c and drivers/scsi/scsi_scan.c, drivers/scsi/scsi_error.c<br> scsi_scan.c contains the scsi discovery code. scsi_error.c contains the error recovery code ..<br>
<br> The main entry point function in scsi middle layer is scsi_request_fn () <a href="http://lxr.linux.no/#linux+v2.6.39/drivers/scsi/scsi_lib.c#L1481">http://lxr.linux.no/#linux+v2.6.39/drivers/scsi/scsi_lib.c#L1481</a><br>
Also look at function scsi_alloc_sdev () in <a href="http://lxr.linux.no/#linux+v2.6.39/drivers/scsi/scsi_scan.c#L238">http://lxr.linux.no/#linux+v2.6.39/drivers/scsi/scsi_scan.c#L238</a> ..<br><br>Regards,<br>Sumeet <br>
</div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
_______________________________________________<br>
Kernelnewbies mailing list<br>
<a href="mailto:Kernelnewbies@kernelnewbies.org">Kernelnewbies@kernelnewbies.org</a><br>
<a href="http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies" target="_blank">http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies</a><br>
</blockquote></div><br>