All of lore.kernel.org
 help / color / mirror / Atom feed
From: Denys Dmytriyenko <denys@ti.com>
To: Karthik Ramanan <a0393906@ti.com>
Cc: meta-arago@arago-project.org
Subject: Re: [RFC PATCH - USB DRD] udev: Add rules for DRD usecase
Date: Tue, 24 Feb 2015 16:13:15 -0500	[thread overview]
Message-ID: <20150224211315.GE4338@edge> (raw)
In-Reply-To: <1423823436-21007-1-git-send-email-a0393906@ti.com>

On Fri, Feb 13, 2015 at 04:00:36PM +0530, Karthik Ramanan wrote:
> For the DRD usecase when switching from host to device mode
> some commands have to be executed manually. These script
> additions facilatate this to happen automatically.

The patch seems fine, but why do you add an extra line at the end of every 
file?


> Signed-off-by: Karthik Ramanan <a0393906@ti.com>
> ---
>  .../recipes-core/udev/udev/local.rules             |    2 ++
>  .../recipes-core/udev/udev/usb1-rules.sh           |    4 ++++
>  .../recipes-core/udev/udev/usb2-rules.sh           |    4 ++++
>  .../recipes-core/udev/udev_182.bbappend            |   14 +++++++++++++-
>  4 files changed, 23 insertions(+), 1 deletion(-)
>  create mode 100755 meta-arago-distro/recipes-core/udev/udev/usb1-rules.sh
>  create mode 100755 meta-arago-distro/recipes-core/udev/udev/usb2-rules.sh
> 
> diff --git a/meta-arago-distro/recipes-core/udev/udev/local.rules b/meta-arago-distro/recipes-core/udev/udev/local.rules
> index 45c3a46..689e093 100644
> --- a/meta-arago-distro/recipes-core/udev/udev/local.rules
> +++ b/meta-arago-distro/recipes-core/udev/udev/local.rules
> @@ -22,3 +22,5 @@ SUBSYSTEM=="input", KERNEL=="event[0-9]*", ENV{ID_INPUT_TOUCHSCREEN}=="1", SYMLI
>  # Auto-mount any SD cards
>  ACTION=="add", KERNEL=="mmcblk[0-9]p[0-9]", SUBSYSTEM=="block", RUN+="/etc/udev/scripts/mount.sh"
>  ACTION=="remove", KERNEL=="mmcblk[0-9]p[0-9]", SUBSYSTEM=="block", RUN+="/etc/udev/scripts/mount.sh"
> +ACTION=="add", DEVPATH=="/devices/44000000\.ocp/48880000\.omap_dwc3_1/48890000\.usb/udc*", RUN+="/usr/bin/usb1-rules.sh"
> +ACTION=="add", DEVPATH=="/devices/44000000\.ocp/488c0000\.omap_dwc3_2/488d0000\.usb/udc*", RUN+="/usr/bin/usb2-rules.sh"
> diff --git a/meta-arago-distro/recipes-core/udev/udev/usb1-rules.sh b/meta-arago-distro/recipes-core/udev/udev/usb1-rules.sh
> new file mode 100755
> index 0000000..8a49cf1
> --- /dev/null
> +++ b/meta-arago-distro/recipes-core/udev/udev/usb1-rules.sh
> @@ -0,0 +1,4 @@
> +#!bin/sh
> +/sbin/modprobe g_ncm -r
> +/sbin/modprobe g_ncm
> +
> diff --git a/meta-arago-distro/recipes-core/udev/udev/usb2-rules.sh b/meta-arago-distro/recipes-core/udev/udev/usb2-rules.sh
> new file mode 100755
> index 0000000..38a8894
> --- /dev/null
> +++ b/meta-arago-distro/recipes-core/udev/udev/usb2-rules.sh
> @@ -0,0 +1,4 @@
> +#!bin/sh
> +/sbin/modprobe g_zero -r
> +/sbin/modprobe g_zero
> +
> diff --git a/meta-arago-distro/recipes-core/udev/udev_182.bbappend b/meta-arago-distro/recipes-core/udev/udev_182.bbappend
> index 838cce8..684f501 100644
> --- a/meta-arago-distro/recipes-core/udev/udev_182.bbappend
> +++ b/meta-arago-distro/recipes-core/udev/udev_182.bbappend
> @@ -5,4 +5,16 @@
>  # look for files in this layer first
>  FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
>  
> -PR_append = "-arago2"
> +PR_append = "-arago3"
> +
> +SRC_URI_append = " \
> +                  file://usb1-rules.sh \
> +                  file://usb2-rules.sh"
> +
> +do_install_append() {
> +    install -d ${D}/${bindir}
> +
> +    install -m 0755 ${WORKDIR}/usb1-rules.sh ${D}${bindir}/usb1-rules.sh
> +    install -m 0755 ${WORKDIR}/usb2-rules.sh ${D}${bindir}/usb2-rules.sh
> +}
> +
> -- 
> 1.7.9.5
> 
> _______________________________________________
> meta-arago mailing list
> meta-arago@arago-project.org
> http://arago-project.org/cgi-bin/mailman/listinfo/meta-arago


      reply	other threads:[~2015-02-24 21:13 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-02-13 10:30 [RFC PATCH - USB DRD] udev: Add rules for DRD usecase Karthik Ramanan
2015-02-24 21:13 ` Denys Dmytriyenko [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150224211315.GE4338@edge \
    --to=denys@ti.com \
    --cc=a0393906@ti.com \
    --cc=meta-arago@arago-project.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.