Re: [patch] Add -C support to tgt-admin

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 2010-07-27 at 14:32 -0700, Chandra Seetharaman wrote:
> Add support to manage multiple control ports.
> 
> Basically add the ability to pass through "-C NNNN" (or --control_port
> NNNN") option to tgtadm
> 
> Signed-Off-By: Chandra Seetharaman <sekharan@xxxxxxxxxx

Thanks!

The first thing I noticed is that this patch isn't against trunk, I
haven't tried, but I doubt it will apply cleanly. You may want to submit
a new patch against trunk.

http://git.kernel.org/?p=linux/kernel/git/tomo/tgt.git;a=summary

>  if ($execute == 1) {
> -	process_targets;
>  	parse_configs;
> +	process_targets;
>  	add_targets;
>  	remove_targets;
>  } elsif ($delete ne 0) {

Please explain this order change.

FWIIW, both &process_targets and &process_accounts (in the latest
tgt-admin) create data structures, did you check to see if those data
structures are used by &parse_configs?

FYI, In git trunk this section of code currently looks like this:

1269 if ($execute == 1) {
1270         process_targets;
1271         process_accounts;
1272         parse_configs;
1273         add_targets;
1274         remove_targets;
1275 } elsif ($delete ne 0) {
1276         delete_targets;
1277 } elsif ($update ne 0) {
1278         process_accounts;
1279         update_targets;
1280 } elsif ($dump == 1) {
1281         dump_config;
1282 } elsif ($offline ne 0) {
1283         ready_offline_targets("offline");
1284 } elsif ($ready ne 0) {
1285         ready_offline_targets("ready");
1286 } else {
1287         print "No action specified.\n";
1288 }

Best regards,
Dax Kelson

--
To unsubscribe from this list: send the line "unsubscribe stgt" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux SCSI]     [Linux RAID]     [Linux Clusters]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]

  Powered by Linux