On Tue, 3 Feb 2009 19:12:38 -0500 Kyle McMartin <kyle@xxxxxxxxxxxxx> wrote: > On Tue, Feb 03, 2009 at 04:09:00PM -0800, Andrew Morton wrote: > > : if (id == ISCSI_MAX_TARGET) { > > : for (id = 0; id < ISCSI_MAX_TARGET; id++) { > > : err = device_for_each_child(&shost->shost_gendev, &id, > > Possibly GCC just can't figure out that id was reinitialized, so it > thinks that the for loop won't be executed? > Could be. But that isn't the point... The point, dear Kyle, is that I misread the code :( In fact on that codepath the function _will_ return the most recent return value from device_for_each_child(iscsi_get_next_target_id), and that value will be non-zero (-EEXIST). So it looks non-buggy, albeit rather obscure. But did we intend to return -EEXIST in the "Too many iscsi targets" case? -- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html