public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Charles-Edouard Ruault <ce@idtect.com>
To: linux-os@analogic.com
Cc: "Randy.Dunlap" <rddunlap@osdl.org>,
	Linux kernel <linux-kernel@vger.kernel.org>
Subject: Re: IO port conflict between timer & watchdog on PCISA-C800EV board ?
Date: Mon, 07 Feb 2005 18:33:30 +0100	[thread overview]
Message-ID: <4207A66A.9020602@idtect.com> (raw)
In-Reply-To: <Pine.LNX.4.61.0502071157520.22576@chaos.analogic.com>

linux-os wrote:

> On Mon, 7 Feb 2005, Randy.Dunlap wrote:
>
>> Charles-Edouard Ruault wrote:
>>
>>> Hi All,
>>>
>>> i wrote a driver for the watchdog timer provided by a small form 
>>> factor board from IEI ( the PCISA-C800EV : 
>>> http://www.iei.com.tw/en/product_IPC.asp?model=PCISA-C800 ).
>>> This board has a Via Apollo PLE133 ( VT8601A and VT82C686B ) chipset.
>>> The watchdog uses two registers at addresses 0x43 and 0x443, 
>>> therefore my driver tries to get bot addresses for its own use calling
>>> request_region(0x43, 1, "watchdog" ) and request_region(0x443, 1, 
>>> "watchdog").
>>> The first call to request 0x43 fails because the address has already 
>>> been allocated to the timer ( /proc/ioports shows 0040-005f : timer ).
>>>
>>> So my questions are :
>>> - Why is the generic timer using this address ? isn't it reserving a 
>>> too wide portion of IO ports ? Should it be modified for this board ?
>>> -  If there's a good reason for the timer to request this address, 
>>> is there a clean way to share it with the timer ?
>>
>>
>> Missing kernel version.... must be "not the current/latest",
>> so early 2.6 or more likely 2.4 (just guessing)?
>>
>> /proc/ioports timer assignments have now been split up like this:
>> 0040-0043 : timer0
>> 0050-0053 : timer1
>>
>> However, port 0x43 is still assigned to timer0, so your request_region
>> call will still fail.  What system board timer resource assignments
>> should be used for that VIA chipset?  If the chipset timer only needs
>> 0x40-0x42, e.g., leaving 0x43 available, then it would be possible
>> to do some kind of workaround (maybe not real clean, but possible).
>>
>> -- 
>> ~Randy
>
>
> The driver can still R/W registers that it hasn't allocated.
> There is no hardware trap preventing this. I suggest that,
> as a temporary work-around, just don't allocate the low
> port, but attempt to use it. I think the watchdog probably
> just looks for read at that address.

Hi Dick,
thanks for the reply. Right now i'm doing exactly what you suggest and 
it works fine ... but i'm not really happy about this "workaround" since 
it's not clean.
The driver reads only at 0x43 to disable the watchdog , i have not seen 
any side effect so far but ... one never knows !

>
>
> Cheers,
> Dick Johnson
> Penguin : Linux version 2.6.10 on an i686 machine (5537.79 BogoMips).
>  Notice : All mail here is now cached for review by Dictator Bush.
>                  98.36% of all statistics are fiction.



-- 
Charles-Edouard Ruault
Idtect SA
115 rue Reaumur - 75002, Paris, France
Tel: +33-1-55-34-76-65
Fax: +33-1-55-34-76-75
Web: http://www.idtect.com


  reply	other threads:[~2005-02-07 17:33 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-02-07  9:29 IO port conflict between timer & watchdog on PCISA-C800EV board ? Charles-Edouard Ruault
2005-02-07 16:31 ` Randy.Dunlap
2005-02-07 17:00   ` linux-os
2005-02-07 17:33     ` Charles-Edouard Ruault [this message]
2005-02-07 17:32   ` Charles-Edouard Ruault
2005-02-07 17:57   ` Ondrej Zary
2005-02-15 17:04 ` Alan Cox
2005-02-21 13:06   ` [PATCH] Reserve only needed regions for PC timers on i386 and x86_64 Charles-Edouard Ruault
2005-02-23  7:23     ` Marcelo Tosatti

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=4207A66A.9020602@idtect.com \
    --to=ce@idtect.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-os@analogic.com \
    --cc=rddunlap@osdl.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