Differences between iscsi and gscsi

Roman Rakus rrakus at redhat.com
Wed Mar 17 02:10:09 EST 2010


On 02/09/2010 05:58 AM, Tony Breeds wrote:
>    
>> Previous patch has a typo. Use this new one.
>> RR
>>      
>    
>> diff -up yaboot-1.3.14/second/prom.c.iscsi yaboot-1.3.14/second/prom.c
>> --- yaboot-1.3.14/second/prom.c.iscsi	2010-02-05 13:12:56.000000000 +0100
>> +++ yaboot-1.3.14/second/prom.c	2010-02-05 13:13:24.000000000 +0100
>> @@ -196,7 +196,7 @@ prom_get_devtype (char *device)
>>        char       tmp[64];
>>
>>        if (strstr(device, TOK_ISCSI))
>> -	  device = strcpy(tmp, "/vdevice/gscsi/disk");
>> +	  return FILE_DEVICE_ISCSI;
>>
>>        /* Find OF device phandle */
>>        dev = prom_finddevice(device);
>>      
> Seems good to me.
>
> Yours Tony
>    
And it only looks to be good and actually isn't. The problems are in 
places, where we call prom_get_devtype(), but we don't check if it 
returns FILE_DEVICE_ISCSI (only _BLOCK and _NET). Following files are 
affected:
second/file.c
second/partition.c
second/yaboot.c
Is it possible to just say that _BLOCK is generally the same as _ISCSI 
(in meaning how we will handle it)? Is iSCSI device handled in open 
firmware similarly as block device?
A bits of my investigation:
second/file.c:open_file() it looks like _BLOCK open works well when we 
get _ISCSI
second/partition.c:get_part_type() maybe same as above
second/yaboot.c: Here are things a bit complicated, but every time we 
compare with _NET, so if we say we will handle _ISCSI same as _BLOCK, 
nothing will change here.

So, the mail question is: Is iSCSI device handled similarly as block device?
RR


More information about the Yaboot-devel mailing list