RE: [PATCH v2 02/11] usbip: readme and manuals about exporting devices

2015-04-23 Thread fx IWATA NOBUO
 I see various parameters, such as --busid, followed by an = sign.
 This looks like a thing thoughout the manual.
 Although this syntax works as well, I think we should be consistent 
 and not include =.
 I, personally, prefer having --busid busid instead of 
 --busid=busid.

I agree. I checked other section 1 and 8 manual pages and they don't 
use '='.
In v3, I will replace '=' with ' ' including used in original.

Thanks,

n.iwata
//
N�r��yb�X��ǧv�^�)޺{.n�+{��^n�r���z���h����G���h�(�階�ݢj���m��z�ޖ���f���h���~�m�

Re: [PATCH v2 02/11] usbip: readme and manuals about exporting devices

2015-04-21 Thread Valentina Manea
On Tue, Apr 14, 2015 at 10:00 AM, Nobuo Iwata
nobuo.iw...@fujixerox.co.jp wrote:

 -server:# usbip bind --busid=1-2
 +dev:# usbip bind --busid=1-2
  - Bind usbip-host.ko to the device of busid 1-2.
 -- A usb device 1-2 is now exportable to other hosts!
 -- Use 'usbip unbind --busid=1-2' when you want to shutdown exporting 
 and use the device locally.
 +- USB device 1-2 is now importable from other computer!
 +
 +dev:# usbip unbind --busid=1-2
 +- Unind usbip-host.ko from the device of busid 1-2.
 +- USB device 1-2 is not importable from other computer.


I see various parameters, such as --busid, followed by an = sign.
This looks like a thing thoughout the manual.
Although this syntax works as well, I think we should be consistent
and not include =.
I, personally, prefer having --busid busid instead of --busid=busid.

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


[PATCH v2 02/11] usbip: readme and manuals about exporting devices

2015-04-14 Thread Nobuo Iwata
This patch adds function and usage of export to README and manuals.

The wording, 'server' and 'client' is changed also.

For existing attach command, the daemon runs device side machine and 
attach command is executed in application side machine. Then 'server' 
is used for device side and 'client' is for application side.

For the new connect command, the daemon runs applications side machine 
and connect command is executed in device side machine. Now, 'server' 
and 'client' run in different machine than before.

So, to avoid confusion, words 'device side' and 'application side' are 
used instead of 'client' and 'server'.

Signed-off-by: Nobuo Iwata nobuo.iw...@fujixerox.co.jp
---
 tools/usb/usbip/Makefile.am  |  2 +-
 tools/usb/usbip/README   | 70 ++--
 tools/usb/usbip/doc/usbip.8  | 74 ++
 tools/usb/usbip/doc/usbipa.8 | 77 
 tools/usb/usbip/doc/usbipd.8 | 29 +++---
 5 files changed, 200 insertions(+), 52 deletions(-)

diff --git a/tools/usb/usbip/Makefile.am b/tools/usb/usbip/Makefile.am
index 66f8bf0..f371ed9 100644
--- a/tools/usb/usbip/Makefile.am
+++ b/tools/usb/usbip/Makefile.am
@@ -3,4 +3,4 @@ includedir = @includedir@/usbip
 include_HEADERS := $(addprefix libsrc/, \
 usbip_common.h vhci_driver.h usbip_host_driver.h)
 
-dist_man_MANS := $(addprefix doc/, usbip.8 usbipd.8)
+dist_man_MANS := $(addprefix doc/, usbip.8 usbipd.8 usbipa.8)
diff --git a/tools/usb/usbip/README b/tools/usb/usbip/README
index 831f49f..74f4afb 100644
--- a/tools/usb/usbip/README
+++ b/tools/usb/usbip/README
@@ -1,7 +1,8 @@
 #
 # README for usbip-utils
 #
-# Copyright (C) 2011 matt mooney m...@muteddisk.com
+# Copyright (C) 2015 Nobuo Iwata
+#   2011 matt mooney m...@muteddisk.com
 #   2005-2008 Takahiro Hirofuchi
 
 
@@ -36,41 +37,70 @@
 
 
 [Usage]
-server:# (Physically attach your USB device.)
+Device-side: a machine has USB device(s).
+Application-side: a machine runs an application software uses remote USB 
device.
 
-server:# insmod usbip-core.ko
-server:# insmod usbip-host.ko
+1) Connect from application-side to device-side.
 
-server:# usbipd -D
+dev:# (Physically attach your USB device.)
+
+dev:# insmod usbip-core.ko
+dev:# insmod usbip-host.ko
+
+dev:# usbipd -D
- Start usbip daemon.
 
-server:# usbip list -l
-   - List driver assignments for USB devices.
+dev:# usbip list -l
+   - List driver assignments for USB devices and their busid.
 
-server:# usbip bind --busid 1-2
-   - Bind usbip-host.ko to the device with busid 1-2.
-   - The USB device 1-2 is now exportable to other hosts!
-   - Use `usbip unbind --busid 1-2' to stop exporting the device.
+dev:# usbip bind --busid busid
+   - Bind usbip-host.ko to the device with busid.
+   - The USB device with busid is now exportable to other hosts!
+   - Use `usbip unbind --busid busid` to stop exporting the device.
 
-client:# insmod usbip-core.ko
-client:# insmod vhci-hcd.ko
+app:# insmod usbip-core.ko
+app:# insmod vhci-hcd.ko
 
-client:# usbip list --remote host
+app:# usbip list --remote host
- List exported USB devices on the host.
 
-client:# usbip attach --remote host --busid 1-2
+app:# usbip attach --remote host --busid busid
- Connect the remote USB device.
 
-client:# usbip port
+app:# usbip port
- Show virtual port status.
 
-client:# usbip detach --port port
+app:# usbip detach --port port
- Detach the USB device.
 
+2) Connect from device-side to application-side.
+
+app:# insmod usbip-core.ko
+app:# insmod vhci-hcd.ko
+
+app:# usbipa -D
+   - Start usbip daemon.
+
+dev:# (Physically attach your USB device.)
+
+dev:# insmod usbip-core.ko
+dev:# insmod usbip-host.ko
+
+dev:# usbip list -l
+   - List driver assignments for USB devices and their busid.
+
+dev:# usbip connect --remote host --busid busid
+   - Bind usbip-host.ko to the device with busid.
+   - The USB device of busid is connected to remote host!
+
+dev:# usbip disconnect --remote host --busid busid
+   - The USB device with busid is disconnected from remote host.
+   - Unbind usbip-host.ko from the device.
+
 
 [Example]
 ---
-   SERVER SIDE
+   DEVICE SIDE
 ---
 Physically attach your USB devices to this host.
 
@@ -131,7 +161,7 @@ Mark the device of busid 3-3.2 as exportable:
 ...
 
 ---
-   CLIENT SIDE
+ APPLICATION SIDE
 ---
 First, let's list available remote devices that are marked as
 exportable on the host.
@@ -170,7 +200,7 @@ Attach a remote USB device:
 deux:# usbip attach --remote 10.0.0.3 --busid 1-1
 port 0 attached
 
-Show the devices attached to this client:
+Show the devices