mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
* [ptxdist] Using PTXDist to build out-of-tree drivers
@ 2014-08-19 20:51 Cindy Gold
  2014-08-20  8:24 ` Marc Kleine-Budde
  0 siblings, 1 reply; 4+ messages in thread
From: Cindy Gold @ 2014-08-19 20:51 UTC (permalink / raw)
  To: ptxdist


[-- Attachment #1.1: Type: text/plain, Size: 467 bytes --]

I would like to experiment with building an "out-of-tree" driver and have
browsed the PTXDist Application Note "Kernel Driver Development". My
version of the board support package (TQMa6x-BSP-REV.0101) doesn't seem to
have any of the .../rules/templates files that are mentioned in the
document.

I am using PTXdist 2013.12.0.

So, is the Application Note out of date or is the Application Note not
applicable to the TQMa6x?

Any help will be appreciated. Thank you!

[-- Attachment #1.2: Type: text/html, Size: 562 bytes --]

[-- Attachment #2: Type: text/plain, Size: 48 bytes --]

-- 
ptxdist mailing list
ptxdist@pengutronix.de

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [ptxdist] Using PTXDist to build out-of-tree drivers
  2014-08-19 20:51 [ptxdist] Using PTXDist to build out-of-tree drivers Cindy Gold
@ 2014-08-20  8:24 ` Marc Kleine-Budde
  2014-08-20 16:30   ` Cindy Gold
  0 siblings, 1 reply; 4+ messages in thread
From: Marc Kleine-Budde @ 2014-08-20  8:24 UTC (permalink / raw)
  To: ptxdist


[-- Attachment #1.1: Type: text/plain, Size: 742 bytes --]

On 08/19/2014 10:51 PM, Cindy Gold wrote:
> I would like to experiment with building an "out-of-tree" driver and
> have browsed the PTXDist Application Note "Kernel Driver Development". My
> version of the board support package (TQMa6x-BSP-REV.0101) doesn't seem
> to have any of the .../rules/templates files that are mentioned in the
> document.

Jürgen's answer still applies:

The template is not part of the BSP, its part of PTXdist itself.

Marc

-- 
Pengutronix e.K.                  | Marc Kleine-Budde           |
Industrial Linux Solutions        | Phone: +49-231-2826-924     |
Vertretung West/Dortmund          | Fax:   +49-5121-206917-5555 |
Amtsgericht Hildesheim, HRA 2686  | http://www.pengutronix.de   |


[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]

[-- Attachment #2: Type: text/plain, Size: 48 bytes --]

-- 
ptxdist mailing list
ptxdist@pengutronix.de

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [ptxdist] Using PTXDist to build out-of-tree drivers
  2014-08-20  8:24 ` Marc Kleine-Budde
@ 2014-08-20 16:30   ` Cindy Gold
  2014-08-21  7:00     ` Juergen Borleis
  0 siblings, 1 reply; 4+ messages in thread
From: Cindy Gold @ 2014-08-20 16:30 UTC (permalink / raw)
  To: ptxdist


[-- Attachment #1.1: Type: text/plain, Size: 1936 bytes --]

Sorry, I guess I am not being clear. I have PTXdist installed here:

/usr/local/lib/ptxdist-2013.12.0

Under that directory, there is indeed a "rules" sub-directory.

The Application Note from this link:

http://pengutronix.com/software/ptxdist/appnotes/AppNote_kernel_driver.pdf

under the "Preparations" section says this:

project$ cp <ptxdist-installdir>/rules/templates/kernel/Makefile
local_src/module-template

project$ cp <ptxdist-installdir>/rules/templates/kernel/*.c
local_src/module-template

There is no sub-directory called "kernel" under the rules directory in my
directory /usr/local/lib/ptxdist-2013.12.0/rules.  There are a variety of
other sub-directories but not one called "kernel". So, it would seem that
the documentation may perhaps be out of date. My questions are:

   --If the App Note is out of date, is there a newer version available?
  -- If there is not a newer version available, then can you tell me what
should be updated?

Thanks,
  Cindy





On Wed, Aug 20, 2014 at 2:24 AM, Marc Kleine-Budde <mkl@pengutronix.de>
wrote:

> On 08/19/2014 10:51 PM, Cindy Gold wrote:
> > I would like to experiment with building an "out-of-tree" driver and
> > have browsed the PTXDist Application Note "Kernel Driver Development". My
> > version of the board support package (TQMa6x-BSP-REV.0101) doesn't seem
> > to have any of the .../rules/templates files that are mentioned in the
> > document.
>
> Jürgen's answer still applies:
>
> The template is not part of the BSP, its part of PTXdist itself.
>
> Marc
>
> --
> Pengutronix e.K.                  | Marc Kleine-Budde           |
> Industrial Linux Solutions        | Phone: +49-231-2826-924     |
> Vertretung West/Dortmund          | Fax:   +49-5121-206917-5555 |
> Amtsgericht Hildesheim, HRA 2686  | http://www.pengutronix.de   |
>
>
> --
> ptxdist mailing list
> ptxdist@pengutronix.de
>
>

[-- Attachment #1.2: Type: text/html, Size: 2981 bytes --]

[-- Attachment #2: Type: text/plain, Size: 48 bytes --]

-- 
ptxdist mailing list
ptxdist@pengutronix.de

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [ptxdist] Using PTXDist to build out-of-tree drivers
  2014-08-20 16:30   ` Cindy Gold
@ 2014-08-21  7:00     ` Juergen Borleis
  0 siblings, 0 replies; 4+ messages in thread
From: Juergen Borleis @ 2014-08-21  7:00 UTC (permalink / raw)
  To: ptxdist; +Cc: Cindy Gold

Hi Cindy,

On Wednesday 20 August 2014 18:30:57 Cindy Gold wrote:
> Sorry, I guess I am not being clear. I have PTXdist installed here:
>
> /usr/local/lib/ptxdist-2013.12.0
>
> Under that directory, there is indeed a "rules" sub-directory.
>
> The Application Note from this link:
>
> http://pengutronix.com/software/ptxdist/appnotes/AppNote_kernel_driver.pdf
>
> under the "Preparations" section says this:
>
> project$ cp <ptxdist-installdir>/rules/templates/kernel/Makefile
> local_src/module-template
>
> project$ cp <ptxdist-installdir>/rules/templates/kernel/*.c
> local_src/module-template

Oh, yes indeed, it is outdated.

> There is no sub-directory called "kernel" under the rules directory in my
> directory /usr/local/lib/ptxdist-2013.12.0/rules.  There are a variety of
> other sub-directories but not one called "kernel". So, it would seem that
> the documentation may perhaps be out of date. My questions are:
>
>    --If the App Note is out of date, is there a newer version available?

Seems I have to re-write it ;)
Alternatively you can read the PTXdist Guru documentation [1], section 4.2.

>   -- If there is not a newer version available, then can you tell me what
> should be updated?

Here we go. Use this way instead:

[jbe@host]> /usr/local/lib/ptxdist-2013.12.0/bin/ptxdist newpackage

usage: 'ptxdist newpackage <type>', where type is:

  host                     create package for development host
  target                   create package for embedded target
  cross                    create cross development package
  klibc                    create package for initramfs built against klibc

  src-autoconf-lib         create autotoolized library
  src-autoconf-prog        create autotoolized binary
  src-autoconf-proglib     create autotoolized binary+library
  src-cmake-prog           create cmake binary
  src-qmake-prog           create qmake binary
  src-linux-driver         create a linux kernel driver
  src-make-prog            create a plain makefile binary
  src-stellaris            create stellaris firmware
  font                     create a font package
  file                     create package to install existing files
  kernel                   create package for an extra kernel
  barebox                  create package for an extra barebox
  image-tgz                create package for a tgz image
  image-genimage           create package for a genimage image

[jbe@host]> /usr/local/lib/ptxdist-2013.12.0/bin/ptxdist newpackage src-linux-driver

ptxdist: creating a new 'src-linux-driver' package:

ptxdist: enter package name...........: mydriver
ptxdist: enter version number.........: 1
ptxdist: enter package author.........: Juergen Borleis <jbe@pengutronix.de>
ptxdist: enter package section........: project_specific

generating rules/mydriver.make
generating rules/mydriver.in

local_src/mydriver-1 does not exist, create? [Y/n] Y
./
./@name@.c
./wizard.sh
./Makefile

Then enable this new package in your menuconfig, modify the file in
"local_src/mydriver-1/mydriver.c", build your rootfs with "ptxdist go".

Happy hacking,
Juergen

[1] http://www.pengutronix.de/oselas/bsp/pengutronix/download/OSELAS.BSP-Pengutronix-Generic-arm-Quickstart.pdf
-- 
Pengutronix e.K.                              | Juergen Borleis             |
Industrial Linux Solutions                    | http://www.pengutronix.de/  |

-- 
ptxdist mailing list
ptxdist@pengutronix.de

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2014-08-21  7:00 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-08-19 20:51 [ptxdist] Using PTXDist to build out-of-tree drivers Cindy Gold
2014-08-20  8:24 ` Marc Kleine-Budde
2014-08-20 16:30   ` Cindy Gold
2014-08-21  7:00     ` Juergen Borleis

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox