* PCI problem
@ 2005-03-18 12:58 srinivas.surabhi
2005-03-18 17:35 ` Mark A. Greer
0 siblings, 1 reply; 4+ messages in thread
From: srinivas.surabhi @ 2005-03-18 12:58 UTC (permalink / raw)
To: linuxppc-embedded
Hi,
We are facing the problem with MVlinux3.1 having kernel 2.4.20 booting
once the PCI is enabled in config kernel.
First Question is it any where required in linux kernel sources to make
the PCI configuration changes...IF so please let me know in which file
??
Even the message "linux kernel banner " which is at the beginning of the
start_kernel function is not seen. Once the multi image( kernel + ram
disk File system) is extracted into RAM. After that it hangs
bootm 0xfef80000 ## Booting image at fef80000 ...
Image Name: MultiImage
Image Type: PowerPC Linux Multi-File Image (gzip compressed)
Data Size: 4647626 Bytes =3D 4.4 MB
Load Address: 00000000
Entry Point: 00000000
Contents:
Image 0: 551181 Bytes =3D 538.3 kB
Image 1: 4096430 Bytes =3D 3.9 MB
Verifying Checksum ... OK
Uncompressing Multi-File Image ... =3D0=3D
OK
Booting Linux
Loading Ramdisk to 07417000, end 077ff1ae ... OK
...Then hangs ....
SO please help me out in finding out the relation of PCI and the
start_kernel. As per my knowledge once the kernel_init is entered then
the pci_init is invoked. But strangely I am seeing with pci enabled,
hang at the very beginning..
Thanks & Rgds
SS
-----Original Message-----
From: wd@denx.de [mailto:wd@denx.de]
Sent: Thursday, February 17, 2005 5:13 PM
To: Srinivas Surabhi (WT01 - EMBEDDED & PRODUCT ENGINEERING SOLUTIONS)
Cc: linuxppc-embedded@ozlabs.org
Subject: Re: Mounta Vista Linux prompt on serial console
In message
<EF9B29C78F41FA488927FCBC7750AF0E08DA14@hyd-mdp-msg.wipro.com> you
wrote:
>
> But the problem is that it was stopping at
>
> "No init found. Try passing init=3D option to kernel". Before that
there
> were no errors. Everthing looks fine Mounted VFS root file system was
also
Fine. So you can mount the root filesystem, but it obviously does not
contain all the required files.
> seen. From the net I understood is that the fstab file was the cause.
So
> edited the filesytem parameter for / as /dev/ram earlier it used to
be
> /dev/root.
No. /etc/fstab has absolutley nothing to do with your problem. The
kernel cannot start the init porocess - make sure init is in the
filesystem, plus all required libraries.
> So please tell me whether the given fstab file will suffice? The
filesystem
This is completley unrelated.
> 2. I have one more doubt /sbin/init utility comes with what package?
> Because in /sbin directory although the init binary is present, not
shown
> in the file system heirarchy view. For eg. if I select DHCPD package
then
> able to see dhcpd related binary in the /sbin similarly my question
was
> which package has to be selected to have init included.
Please contact MV support. I have no idea how they package their
distribution, or how their config tools might work. You paid for
their stuff, so ask _them_.
Best regards,
Wolfgang Denk
--
See us @ Embedded World, Nuremberg, Feb 22 - 24, Hall 10.0 Booth 310
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de
The most exciting phrase to hear in science, the one that heralds new
discoveries, is not "Eureka!" (I found it!) but "That's funny ..."
-- Isaac Asimov
Confidentiality Notice
The information contained in this electronic message and any attachments
to this message are intended
for the exclusive use of the addressee(s) and may contain confidential
or privileged information. If
you are not the intended recipient, please notify the sender at Wipro or
Mailadmin@wipro.com immediately
and destroy all copies of this message and any attachments.
_______________________________________________
Linuxppc-embedded mailing list
Linuxppc-embedded@ozlabs.org
https://ozlabs.org/mailman/listinfo/linuxppc-embedded
Confidentiality Notice=0D
The information contained in this electronic message and any attachments to=
this message are intended
for the exclusive use of the addressee(s) and may contain confidential or=
privileged information. If
you are not the intended recipient, please notify the sender at Wipro or=
Mailadmin@wipro.com immediately
and destroy all copies of this message and any attachments.
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: PCI problem
2005-03-18 12:58 PCI problem srinivas.surabhi
@ 2005-03-18 17:35 ` Mark A. Greer
0 siblings, 0 replies; 4+ messages in thread
From: Mark A. Greer @ 2005-03-18 17:35 UTC (permalink / raw)
To: srinivas.surabhi; +Cc: linuxppc-embedded
srinivas.surabhi@wipro.com wrote:
>Hi,
>
>We are facing the problem with MVlinux3.1 having kernel 2.4.20 booting
>once the PCI is enabled in config kernel.
>
>First Question is it any where required in linux kernel sources to make
>the PCI configuration changes...IF so please let me know in which file
>??
>
>Even the message "linux kernel banner " which is at the beginning of the
>start_kernel function is not seen. Once the multi image( kernel + ram
>disk File system) is extracted into RAM. After that it hangs
>
>
>bootm 0xfef80000 ## Booting image at fef80000 ...
> Image Name: MultiImage
> Image Type: PowerPC Linux Multi-File Image (gzip compressed)
> Data Size: 4647626 Bytes = 4.4 MB
> Load Address: 00000000
> Entry Point: 00000000
> Contents:
> Image 0: 551181 Bytes = 538.3 kB
> Image 1: 4096430 Bytes = 3.9 MB
> Verifying Checksum ... OK
> Uncompressing Multi-File Image ... =0=
>OK
>Booting Linux
> Loading Ramdisk to 07417000, end 077ff1ae ... OK
>
>...Then hangs ....
>
>SO please help me out in finding out the relation of PCI and the
>start_kernel. As per my knowledge once the kernel_init is entered then
>the pci_init is invoked. But strangely I am seeing with pci enabled,
>hang at the very beginning..
>
>Thanks & Rgds
>SS
>
>-----Original Message-----
>From: wd@denx.de [mailto:wd@denx.de]
>
>Sent: Thursday, February 17, 2005 5:13 PM
>To: Srinivas Surabhi (WT01 - EMBEDDED & PRODUCT ENGINEERING SOLUTIONS)
>Cc: linuxppc-embedded@ozlabs.org
>Subject: Re: Mounta Vista Linux prompt on serial console
>
>
>In message
><EF9B29C78F41FA488927FCBC7750AF0E08DA14@hyd-mdp-msg.wipro.com> you
>wrote:
>
>
>
>
>
>>But the problem is that it was stopping at
>>
>>
>>
>
>
>
>>"No init found. Try passing init= option to kernel". Before that
>>
>>
>there
>
>
>> were no errors. Everthing looks fine Mounted VFS root file system was
>>
>>
>also
>
>Fine. So you can mount the root filesystem, but it obviously does not
>contain all the required files.
>
>
>
>> seen. From the net I understood is that the fstab file was the cause.
>>
>>
>So
>
>
>> edited the filesytem parameter for / as /dev/ram earlier it used to
>>
>>
>be
>
>
>> /dev/root.
>>
>>
>
>No. /etc/fstab has absolutley nothing to do with your problem. The
>kernel cannot start the init porocess - make sure init is in the
>filesystem, plus all required libraries.
>
>
>
>>So please tell me whether the given fstab file will suffice? The
>>
>>
>filesystem
>
>This is completley unrelated.
>
>
>
>>2. I have one more doubt /sbin/init utility comes with what package?
>> Because in /sbin directory although the init binary is present, not
>>
>>
>shown
>
>
>> in the file system heirarchy view. For eg. if I select DHCPD package
>>
>>
>then
>
>
>> able to see dhcpd related binary in the /sbin similarly my question
>>
>>
>was
>
>
>> which package has to be selected to have init included.
>>
>>
>
>Please contact MV support. I have no idea how they package their
>distribution, or how their config tools might work. You paid for
>their stuff, so ask _them_.
>
>Best regards,
>
>Wolfgang Denk
>
Srinivas,
1) Please don't post the same question twice to the same mailing list.
2) Please stop replying to a msg in an existing thread when you start a
new thread. Go look at
http://ozlabs.org/pipermail/linuxppc-embedded/2005-March/thread.html.
Your new thread appear as though its part of 440GX 2.6 NAP thread. It
looks like you've done that in other threads too.
3) When you ask a question, please provide enough detail so that there
is at least the possibility that someone else can help you. What
platform is this on? Did this kernel ever work for you on that
platform? If so, then what have you changed?
4) Heed Wolfgang's advice...if you actually did pay MontaVista for
support then you should be contacting them.
Mark
^ permalink raw reply [flat|nested] 4+ messages in thread
* Help needed. (long)
@ 2003-05-19 9:40 Eliot Blennerhassett
2003-05-19 16:10 ` PCI problem Giuliano Pochini
0 siblings, 1 reply; 4+ messages in thread
From: Eliot Blennerhassett @ 2003-05-19 9:40 UTC (permalink / raw)
To: alsa-devel; +Cc: eliot
Greetings,
(Aside: I still can only post to this list via a web mailer, so apologies if the
formatting is messed up. Still looking for a way to find out what is wrong with
my POP mailer.
Also I'd like to attach a file, but I cant...)
Whereas I have pressed the reset button for the Nth time,
Whereas I have little experience in driver writing,
Whereas I am going around in circles,
Therefore, I have resolved to swallow my pride and subject my code to the
scrutiny of my superiors (in terms of ALSA driver knowledge at least...)
If there is someone out there who can answer the following questions, and is
also interested and able in developing the driver further in exchange for an
AudioScience card (6114, 6122, or 5111)please let me know.
1) Am I understanding this correctly?
I see this kind of sequence:
prepare
copy
copy
copy
trigger(start)
(driver calls period_elapsed)
pointer
copy
pointer
pointer
copy
pointer
pointer
pointer
trigger(stop)
The middle-layer expects that the pointer will be increasing (modulo the buffer
size).
It expects that it should have increased by (at least) the period every time
snd_pcm_period_elapsed is called.
When the middle-layer enters the draining state, the copy callback isn't called
any more.
What is supposed to happen to the pointer now, and how many more times is
period_elapsed expected to be called?
I ask because on our cards when data runs out, the 'pointer' stops moving.
When this happens, and I don't call period_elapsed, then aplay hangs for a while
before erroring out - "failed to exit drained state"
==========================
What I am basically trying to do is translate the following into the PCM
playback part of an ALSA driver.
<code>
wHE = HPI_OutStreamGetInfoEx( phSubSys, pOS->hOutStream,
&wState, &dwBufferSize,
&dwBytesToPlay, &dwSamplesPlayed, NULL);
Data.dwpbData = (HW32)&dataBuffer;
while((dwBytesToPlay<(dwBufferSize-BLOCK_SIZE)))
{
dwBytesRead=read_some_data(&dataBuffer);
Data.dwDataSize = dwBytesRead;
wHE = HPI_OutStreamWrite( phSubSys, pOS->hOutStream, &Data);
wHE = HPI_OutStreamGetInfo( phSubSys, pOS->hOutStream,
&wState, &dwBufferSize, &dwBytesToPlay);
}
</code>
Notes:
wXxxx is 16 bit data, dwXxxx is 32 bit.
wState: STOPPED, PLAYING, DRAINED=ran out of data.
dwBufferSize typically 500K to 1Mbyte
Data is a struct that contains a pointer to data buffer, size of data, and
format info.
Our cards have no interrupts, and no DMA (...yet. The next one probably will) so
they must be polled.
Based on the dummy driver, I am using a timer to do the polling.
So far, it does play audio, but often crashes or locks the machine solid with a
kernel panic.
I need help with the subtleties, and any tips on how to debug this kind of
problem ;-)
static void snd_card_asihpi_pcm_timer_function(unsigned long data)
{
snd_card_asihpi_pcm_t *dpcm = snd_magic_cast(snd_card_asihpi_pcm_t, (void
*)data, return);
snd_pcm_runtime_t *runtime = dpcm->substream->runtime;
unsigned int pos;
int delta;
HW16 wState,err;
HW32 dwBufferSize;
HW32 dwDataToPlay;
HW32 dwSamplesPlayed;
dpcm->timer.expires = 1 + jiffies;
add_timer(&dpcm->timer);
spin_lock_irq(&dpcm->lock);
err= HPI_OutStreamGetInfoEx(phSubSys,dpcm->hStream,
&wState,
&dwBufferSize,
&dwDataToPlay,
&dwSamplesPlayed,
NULL);
HPI_HandleError( err );
// if ((wState== HPI_STATE_DRAINED))
// snd_pcm_stop(dpcm->substream, SNDRV_PCM_STATE_SETUP);
pos = frames_to_bytes(runtime, dwSamplesPlayed);
pos %= dpcm->pcm_size;
delta = pos - dpcm->pcm_buf_pos;
dpcm->pcm_buf_pos = pos;
if (delta < 0) delta += dpcm->pcm_size;
dpcm->pcm_irq_pos += delta;
if (dpcm->pcm_irq_pos >= dpcm->pcm_count) {
dpcm->pcm_irq_pos %= dpcm->pcm_count;
snd_pcm_period_elapsed(dpcm->substream);
}
spin_unlock_irq(&dpcm->lock);
}
static snd_pcm_uframes_t snd_card_asihpi_playback_pointer(snd_pcm_substream_t *
substream)
{
snd_pcm_runtime_t *runtime = substream->runtime;
snd_card_asihpi_pcm_t *dpcm = snd_magic_cast(snd_card_asihpi_pcm_t,
runtime->private_data, return -ENXIO);
snd_printd(KERN_INFO "playback pointer\n");
return bytes_to_frames(runtime, dpcm->pcm_buf_pos);
}
static int snd_card_asihpi_playback_copy(
snd_pcm_substream_t *substream, int channel,
snd_pcm_uframes_t pos,
void *src,
snd_pcm_uframes_t count)
{
snd_pcm_runtime_t *runtime = substream->runtime;
snd_card_asihpi_pcm_t *dpcm = snd_magic_cast(snd_card_asihpi_pcm_t,
runtime->private_data, return -ENXIO);
HW16 err;
unsigned int len;
len = frames_to_bytes(runtime, count);
if (copy_from_user(runtime->dma_area, src, len))
return -EFAULT;
dpcm->Data.dwDataSize = len;
dpcm->Data.dwpbData = (HW32)runtime->dma_area;
err = HPI_OutStreamWrite(phSubSys,dpcm->hStream,&dpcm->Data);
return 0;
}
Is this an appropriate way to structure the driver?
If not, then how?
Thanks for wading through...
Eliot Blennerhassett
www.audioscience.com
Eliot Blennerhassett
AudioScience Inc.
--
Junk footer beyond this point. Read at your own risk.
-------------------------------------------------------------
Sign up for ICQmail at http://www.icq.com/icqmail/signup.html
-------------------------------------------------------
This SF.net email is sponsored by: If flattening out C++ or Java
code to make your application fit in a relational database is painful,
don't do it! Check out ObjectStore. Now part of Progress Software.
http://www.objectstore.net/sourceforge
^ permalink raw reply [flat|nested] 4+ messages in thread* PCI problem
2003-05-19 9:40 Help needed. (long) Eliot Blennerhassett
@ 2003-05-19 16:10 ` Giuliano Pochini
2003-05-20 9:01 ` Takashi Iwai
0 siblings, 1 reply; 4+ messages in thread
From: Giuliano Pochini @ 2003-05-19 16:10 UTC (permalink / raw)
To: alsa-devel
I would like some hints on this problem. When I load the module
the machine hangs solid or it works fine depending on which
PCI bus slot the card is. Initializations completes if the card
is in a slot that shares IRQ with something (ethernet IIRC). The
card doesn't send IRQs during init.
When I try to play something the box crashed badly:
>Start Transport
>uhci ac00 host system error, PCI problem?
>uhci ac00 host controller process error, something bad happened.
>uhci ac00 host controller halted. Very bad.
:( Any ideas ?
I don't own that card, I just reported what a betatester told
me. The card works fine under windos. Another person has the
same card and no problems.
Bye.
-------------------------------------------------------
This SF.net email is sponsored by: If flattening out C++ or Java
code to make your application fit in a relational database is painful,
don't do it! Check out ObjectStore. Now part of Progress Software.
http://www.objectstore.net/sourceforge
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: PCI problem
2003-05-19 16:10 ` PCI problem Giuliano Pochini
@ 2003-05-20 9:01 ` Takashi Iwai
0 siblings, 0 replies; 4+ messages in thread
From: Takashi Iwai @ 2003-05-20 9:01 UTC (permalink / raw)
To: Giuliano Pochini; +Cc: alsa-devel
At Mon, 19 May 2003 18:10:29 +0200 (CEST),
Giuliano Pochini wrote:
>
>
> I would like some hints on this problem. When I load the module
> the machine hangs solid or it works fine depending on which
> PCI bus slot the card is. Initializations completes if the card
> is in a slot that shares IRQ with something (ethernet IIRC). The
> card doesn't send IRQs during init.
the irq handler of your driver receives too many unknown interrupts
from other devices constantly?
this might be the reason of hang up, too.
Takashi
-------------------------------------------------------
This SF.net email is sponsored by: ObjectStore.
If flattening out C++ or Java code to make your application fit in a
relational database is painful, don't do it! Check out ObjectStore.
Now part of Progress Software. http://www.objectstore.net/sourceforge
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2005-03-18 17:35 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-03-18 12:58 PCI problem srinivas.surabhi
2005-03-18 17:35 ` Mark A. Greer
-- strict thread matches above, loose matches on Subject: below --
2003-05-19 9:40 Help needed. (long) Eliot Blennerhassett
2003-05-19 16:10 ` PCI problem Giuliano Pochini
2003-05-20 9:01 ` Takashi Iwai
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.