From: dk-arm-linux@gmx.de (Dieter Kiermaier)
To: linux-arm-kernel@lists.infradead.org
Subject: ARM kirkwood: how to run kirkwood_pcie_init() from kernel module
Date: Wed, 18 Nov 2009 08:09:35 +0100 [thread overview]
Message-ID: <200911180809.36672.dk-arm-linux@gmx.de> (raw)
In-Reply-To: <c70ff3ad0911171910t2231317aw154ba6e455ca3511@mail.gmail.com>
Hi,
> please note that this function linked into the init section.
I was not able to call the kirkwood_pcie_init. Is there a way?
My idea after fighting a few hours with this issue was that
I couldn't call init functions because init code is freed from kernel after bootup,
isn't it?
But finally I got it working with fakephp by doing:
#disconnect my fpga
echo 0 > /sys/bus/pci/slots/0000:01:08.0/power
#disconnect my bridge
echo 0 > /sys/bus/pci/slots/0000:00:01.0/power
#
flashing my fpga.......
#initiate bus rescan
echo 1 > /sys/bus/pci/rescan
I have no idea why it doesn't work without fakephp (because pci subsystem also allows disabling
the devices via sysfs) but if I did it without fakephp
echo 1 > /sys/bus/pci/rescan
has absolutely no effect.
But now it works as expected.
Many thanks,
Dieter
>
> On Mon, Nov 16, 2009 at 3:32 AM, Dieter Kiermaier <dk-arm-linux@gmx.de> wrote:
> > Hi all,
> >
> > sorry for disturbing and also sorry for my - maybe strange - question ;)
> >
> > I've got the following problem:
> >
> > I want to boot my fpga before I start the pci layer.
> > To achieve this it is necessary to start the pci layer somewhat after flashing my fpga.
> >
> > So what I need is to run kirkwood_pcie_init() from inside my (flashing) driver.
> > Do you know a way how to realize this?
> >
> > The header common.h isn't meant to include it from anywhere else than from kirkwood *_setup.c files, right?
> >
> > Is it possible to do a EXPORT_SYMBOL(kirkwood_pcie_init) somehow?
> >
> > I've tried it allready but get linker warnings and function isn't called...
> >
> > Do you have an idea how I can do that?
> >
> > Many many thanks in advance,
> > Dieter
> >
> > _______________________________________________
> > linux-arm-kernel mailing list
> > linux-arm-kernel at lists.infradead.org
> > http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
> >
>
> _______________________________________________
> linux-arm-kernel mailing list
> linux-arm-kernel at lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
>
prev parent reply other threads:[~2009-11-18 7:09 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-11-16 9:32 ARM kirkwood: how to run kirkwood_pcie_init() from kernel module Dieter Kiermaier
2009-11-18 3:10 ` saeed bishara
2009-11-18 7:09 ` Dieter Kiermaier [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=200911180809.36672.dk-arm-linux@gmx.de \
--to=dk-arm-linux@gmx.de \
--cc=linux-arm-kernel@lists.infradead.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).