-
Notifications
You must be signed in to change notification settings - Fork 90
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
don't ask for size when creating backstore for existing file #1
Comments
fixed in 2.1.fb2 |
agrover
pushed a commit
that referenced
this issue
Jun 12, 2012
|root@squsb:~# mount a -t configfs /sys/kernel/config |root@squsb:~# modprobe dummy_hcd |root@squsb:~# targetcli |Welcome to the targetcli shell: | | Copyright (c) 2011 by RisingTide Systems LLC. | |Visit us at http://www.risingtidesystems.com. | |Can't load fabric module qla2xxx. |Can't load fabric module ib_srpt. |Loaded iscsi_target_mod kernel module. |Created '/sys/kernel/config/target/iscsi'. |Done loading iscsi fabric module. |Created '/sys/kernel/config/target/loopback'. |Done loading loopback fabric module. |Can't load fabric module tcm_fc. |Created '/sys/kernel/config/target/usb_gadget'. |Done loading usb_gadget fabric module. | |/backstores/rd_mcp> create disk 256M |Generating a wwn serial. |Created rd_mcp ramdisk disk with size 256M. |Entering new node /backstores/rd_mcp/disk | |/usb_gadget> create |Created target naa.60014052d9f751dd. |Entering new node /usb_gadget/naa.60014052d9f751dd |/usb_gadget/n...14052d9f751dd> cd luns |/usb_gadget/n...d9f751dd/luns> create /backstores/rd_mcp/disk |Selected LUN 0. |Successfully created LUN 0. |Entering new node /usb_gadget/naa.60014052d9f751dd/luns/lun0 |/usb_gadget/n...1dd/luns/lun0> |/usb_gadget/n...1dd/luns/lun0> cd .. |/usb_gadget/n...d9f751dd/luns> cd .. |/usb_gadget/n...14052d9f751dd> disable |The TPGT has been disabled. |/usb_gadget/n...14052d9f751dd> enable |The TPGT has been enabled. after that on the host side: |[ 227.097768] usb 1-1: configuration #1 chosen from 1 choice |[ 227.100157] gadget: high-speed config #1: Linux Target |[ 227.102934] Using the BOT protocol |[ 227.115756] Using the UAS protocol |[ 227.121483] scsi1 : uas |[ 227.128314] scsi 1:0:0:0: Direct-Access LIO-ORG RAMDISK-MCP 4.0 PQ: 0 ANSI: 5 TAG: 1 |[ 227.164322] sd 1:0:0:0: [sda] 524288 512-byte logical blocks: (268 MB/256 MiB) |[ 227.204283] sd 1:0:0:0: [sda] Write Protect is off |[ 227.204904] sd 1:0:0:0: [sda] Mode Sense: 2f 00 00 00 |[ 227.220285] sd 1:0:0:0: [sda] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA |[ 227.300319] sda: unknown partition table |[ 227.376286] sd 1:0:0:0: [sda] Attached SCSI disk Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Signed-off-by: Andy Grover <agrover@redhat.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Why must we specify file size when creating a file backstore? We should simply use the size of the existing file (if present).
If the file does not exist, then we can create it using the given file size.
The text was updated successfully, but these errors were encountered: