All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andreas Ziegler <br015@umbiko.net>
To: Dan Jackson <dan@thejacksons.uk>
Cc: Buildroot <buildroot@buildroot.org>
Subject: Re: [Buildroot] Adding USB support to existing device on 2.6.39.3 kernel - possible?
Date: Tue, 29 Mar 2022 09:40:26 +0000	[thread overview]
Message-ID: <2854f91f1188e166bf02e3a6ab6249a4@umbiko.net> (raw)
In-Reply-To: <mailman.22068.1648533484.192135.buildroot@buildroot.org>

Hi Dan,

On 2022-03-29 05:58, Dan Jackson <dan@thejacksons.uk> wrote:

> Hello,
> 
> Sorry once again if this is a silly/noob question.
> 
> If I have an existing router device running a 2.6.39.3 kernel, which
> has a USB port and is capable of supporting USB devices, but the
> manufacturer has removed/not installed the necessary kernel modules,
> can I use Buildroot to recreate the missing modules and thus re-enable
> the missing USB support?

It might work: the driver is contained in the USB module, so building 
and loading that module could do the trick.

> If so, how would I do it?

Supposing the Linux kernel source contained in [1] is the one that is 
running on your device, you need to configure Buildroot to build a Linux 
kernel (BR2_LINUX_KERNEL). The manual [2] has some information about how 
to do this for a Kernel source tree (see chapter 8.14.6).

You then need to enable USB support in the kernel (Device Drivers -> USB 
support), probably

   CONFIG_USB=m
   CONFIG_USB_EHCI_HCD=y
   CONFIG_USB_OHCI_HCD=y

is enough, otherwise try some of the hardware specific (driver) options.

Copy usbcore.ko from Buildroot target/lib/modules/{kernel-version}/ to 
the corresponding location on your device and load the driver with 
modprobe.

Depending on which functionality (e.g. USB_STORAGE) you want on your USB 
port, additional configurations changes may be necessary.

Kind regards,
Andreas

> This time I successfully managed to build other binaries (e.g.
> dropbear, busybox) which run OK on the device.
> 
> Thanks,
> Dan Jackson.
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL:
> <http://lists.buildroot.org/pipermail/buildroot/attachments/20220329/43c49a2d/attachment.html>

[1] 
https://sourceforge.net/projects/dg3270.arris/files/DG3270_9.1.103FB/
[2] https://buildroot.org/downloads/manual/manual.html#_advanced_usage,
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

       reply	other threads:[~2022-03-29  9:40 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <mailman.22068.1648533484.192135.buildroot@buildroot.org>
2022-03-29  9:40 ` Andreas Ziegler [this message]
2022-03-29 12:48   ` [Buildroot] Adding USB support to existing device on 2.6.39.3 kernel - possible? Dan Jackson
2022-03-29 15:13     ` Andreas Ziegler
2022-03-29 16:17       ` Dan Jackson
2022-03-29 17:52         ` Andreas Ziegler
2022-03-29 19:19           ` Dan Jackson
2022-03-30  7:13             ` Andreas Ziegler
2022-03-30 19:18               ` Dan Jackson
2022-03-31  5:57                 ` Andreas Ziegler
2022-03-31  6:19                   ` Dan Jackson
2022-03-31  6:50                     ` Andreas Ziegler
2022-03-29  5:57 Dan Jackson

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=2854f91f1188e166bf02e3a6ab6249a4@umbiko.net \
    --to=br015@umbiko.net \
    --cc=buildroot@buildroot.org \
    --cc=dan@thejacksons.uk \
    /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.