ts-7000
[Top] [All Lists]

[ts-7000] Re: TS-7400 DIO from kernel space

To:
Subject: [ts-7000] Re: TS-7400 DIO from kernel space
From: Alexander Clouter <>
Date: Sat, 15 Mar 2008 12:05:41 +0000
Hi,

basement_mobile2004 <> [20080314 16:02:57 -0000]:
>
> Digging books and tutorials I finally did it. 0x12000000 is a reserved 
> memory space and can't be accessed directly. We have to remap that region 
> to a random memory space area via kernel functions to do so. I'll post the 
> snippet of the code to do that below:
>
> [snipped] 
> 
> Hope that helps you.
>
Thanks, this helps immensely.  Looking at the sourcecode I can now see all 
the references to ioremap()[1] and my brain is not just glazing over it 
thinking "hmmm don't know what it means, just ignore it and it might go away" 
:)

Anyway, I figured out that the FPGA lives at 0xe8000000 rather than the PCI 
bus[2] (hence why the regular orion port hangs when scanning the 'pci bus').  
With this and you help I have the RTC working :) As for the NAND code, is no 
longer oops'ing, just not finding the chips...but I'm closer.

Code is at the usual place if anyone is interested:

http://www.digriz.org.uk/ts-7800

Cheers

Alex

[1] needed to use __arm_ioremap() though 
[2] probably purposely done for when the PCI bitstream from the FPGA arrives?  
        However as there is nothing on the PCI(e) buses, who cares? :)

> --- In  Alexander Clouter <> wrote:
> >
> > Hi,
> > 
> > basement_mobile2004 <> [20080313 13:41:06 -0000]:
> > >
> > > I'm trying to access DIO registers from kernel space but it
> > > redirects the address to upper addresses.
> > >
> > > [snipped]
> > > 
> > > Result:
> > > Unable to handle kernel paging request at virtual address 72000000
> > > pgd = c511c000
> > > [72000000] *pgd=00000000, *pmd = 00000000
> > >
> > don't get excited, I'm curious about the answer to this too.  I have
> no idea 
> > about physical and virtual memory; however I would have expected the
> macros
> > __phys_to_virt() and __virt_to_phys() to have helped me.
> > 
> > Once I know this secret, the regular rtc-m48t86.c driver in the
> linux kernel 
> > will work along with (hopefully) the orion_nand.c MTD driver.
> > 
> > A plea to the Clued(tm) out there....pointers please.  :)
> > 
> > Cheers
> > 
> > Alex
> > 
> > -- 
> >  ________________________________________
> > / To err is human. To blame someone else \
> > \ for your mistakes is even more human.  /
> >  ----------------------------------------
> >         \   ^__^
> >          \  (oo)\_______
> >             (__)\       )\/\
> >                 ||----w |
> >                 ||     ||
> >
> 
> 

-- 
 __________________________________
< If it ain't broke, don't fix it. >
 ----------------------------------
        \   ^__^
         \  (oo)\_______
            (__)\       )\/\
                ||----w |
                ||     ||

------------------------------------

Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/ts-7000/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/ts-7000/join
    (Yahoo! ID required)

<*> To change settings via email:
     
    

<*> To unsubscribe from this group, send an email to:
    

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/

<Prev in Thread] Current Thread [Next in Thread>
Admin

Disclaimer: Neither Andrew Taylor nor the University of NSW School of Computer and Engineering take any responsibility for the contents of this archive. It is purely a compilation of material sent by many people to the birding-aus mailing list. It has not been checked for accuracy nor its content verified in any way. If you wish to get material removed from the archive or have other queries about the archive e-mail Andrew Taylor at this address: andrewt@cse.unsw.EDU.AU