public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* [ECOS] CF driver
@ 2001-05-21  3:53 Andrea Acquaviva
  2001-05-21  7:03 ` Gary Thomas
  0 siblings, 1 reply; 6+ messages in thread
From: Andrea Acquaviva @ 2001-05-21  3:53 UTC (permalink / raw)
  To: ecos-discuss

Hi all,

I'm writing an eCos driver for the CF interface on my Strongarm 1100
based board. I'm modifing the same driver written for the assabet board.
The main difference is that the assabet driver uses the SA1110 to
program the pcmcia interface, while on my board there is not the SA1110
companion chip.

In the assabet driver the CF is programmed also by writing on the BCR
register of the SA1110, in particular the interesting instruction is:

 assabet_BCR(SA1110_BCR_CF_POWER |
                        SA1110_BCR_CF_RESET |
                        SA1110_BCR_CF_BUS,
                        SA1110_BCR_CF_POWER_ON |
                        SA1110_BCR_CF_RESET_ENABLE |
                        SA1110_BCR_CF_BUS_ON);

My question is: what's the mean of the SA1110_BCR_CF_BUS flag? Is it a
particular assabet feature or do it perform some actions on the
PCMCIA interface pins that I must be aware?

Thanks for your help,
Andrea.



--
Ing. Andrea Acquaviva
D.E.I.S. - Universita' di Bologna
V.le Risorgimento, 2    40136 BOLOGNA (ITALY)
Tel: (+39) 051 20 93787 Fax: (+39) 051 2093786



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

* RE: [ECOS] CF driver
  2001-05-21  3:53 [ECOS] CF driver Andrea Acquaviva
@ 2001-05-21  7:03 ` Gary Thomas
  2001-05-21  9:02   ` Andrea Acquaviva
  0 siblings, 1 reply; 6+ messages in thread
From: Gary Thomas @ 2001-05-21  7:03 UTC (permalink / raw)
  To: Andrea Acquaviva; +Cc: ecos-discuss

 
On 21-May-2001 Andrea Acquaviva wrote:
> Hi all,
> 
> I'm writing an eCos driver for the CF interface on my Strongarm 1100
> based board. I'm modifing the same driver written for the assabet board.
> The main difference is that the assabet driver uses the SA1110 to
> program the pcmcia interface, while on my board there is not the SA1110
> companion chip.
> 
> In the assabet driver the CF is programmed also by writing on the BCR
> register of the SA1110, in particular the interesting instruction is:
> 
>  assabet_BCR(SA1110_BCR_CF_POWER |
>                         SA1110_BCR_CF_RESET |
>                         SA1110_BCR_CF_BUS,
>                         SA1110_BCR_CF_POWER_ON |
>                         SA1110_BCR_CF_RESET_ENABLE |
>                         SA1110_BCR_CF_BUS_ON);
> 
> My question is: what's the mean of the SA1110_BCR_CF_BUS flag? Is it a
> particular assabet feature or do it perform some actions on the
> PCMCIA interface pins that I must be aware?

The interface on the SA1110 can be controlled by three different pins.

  Power - whether or not Vcc is applied to the bus
  Bus   - whether or not the bus drivers are enabled
  Reset - whether or not the device is in reset

Not all controllers allow for such fine control.  In many cases, the
power and bus controls are grouped together. 

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

* Re: [ECOS] CF driver
  2001-05-21  7:03 ` Gary Thomas
@ 2001-05-21  9:02   ` Andrea Acquaviva
  2001-05-21  9:13     ` Gary Thomas
  0 siblings, 1 reply; 6+ messages in thread
From: Andrea Acquaviva @ 2001-05-21  9:02 UTC (permalink / raw)
  To: Gary Thomas; +Cc: ecos-discuss

Gary Thomas wrote:

>
> On 21-May-2001 Andrea Acquaviva wrote:
> > Hi all,
> >
> > I'm writing an eCos driver for the CF interface on my Strongarm 1100
> > based board. I'm modifing the same driver written for the assabet board.
> > The main difference is that the assabet driver uses the SA1110 to
> > program the pcmcia interface, while on my board there is not the SA1110
> > companion chip.
> >
> > In the assabet driver the CF is programmed also by writing on the BCR
> > register of the SA1110, in particular the interesting instruction is:
> >
> >  assabet_BCR(SA1110_BCR_CF_POWER |
> >                         SA1110_BCR_CF_RESET |
> >                         SA1110_BCR_CF_BUS,
> >                         SA1110_BCR_CF_POWER_ON |
> >                         SA1110_BCR_CF_RESET_ENABLE |
> >                         SA1110_BCR_CF_BUS_ON);
> >
> > My question is: what's the mean of the SA1110_BCR_CF_BUS flag? Is it a
> > particular assabet feature or do it perform some actions on the
> > PCMCIA interface pins that I must be aware?
>
> The interface on the SA1110 can be controlled by three different pins.
>
>   Power - whether or not Vcc is applied to the bus
>   Bus   - whether or not the bus drivers are enabled
>   Reset - whether or not the device is in reset
>
> Not all controllers allow for such fine control.  In many cases, the
> power and bus controls are grouped together.

Ok, thanks.
Now I have another question:
I have to build the add the net package, but I find an error during the
compilation:

ecoscvs/ecos/packages-net/net/tcpip/current/src/ecos/support.c:85: #error At
least one network driver
framework must be defined!

I found that the problem is that CYGPKG_NET_DRIVER_FRAMEWORK is missing. How
must I define it ?

Thanks a lot for your help,
Andrea.


--
Ing. Andrea Acquaviva
D.E.I.S. - Universita' di Bologna
V.le Risorgimento, 2    40136 BOLOGNA (ITALY)
Tel: (+39) 051 20 93787 Fax: (+39) 051 2093786



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

* Re: [ECOS] CF driver
  2001-05-21  9:02   ` Andrea Acquaviva
@ 2001-05-21  9:13     ` Gary Thomas
  2001-05-21  9:42       ` Andrea Acquaviva
  0 siblings, 1 reply; 6+ messages in thread
From: Gary Thomas @ 2001-05-21  9:13 UTC (permalink / raw)
  To: Andrea Acquaviva; +Cc: ecos-discuss

On 21-May-2001 Andrea Acquaviva wrote:
> Gary Thomas wrote:
> 
>>
>> On 21-May-2001 Andrea Acquaviva wrote:
>> > Hi all,
>> >
>> > I'm writing an eCos driver for the CF interface on my Strongarm 1100
>> > based board. I'm modifing the same driver written for the assabet board.
>> > The main difference is that the assabet driver uses the SA1110 to
>> > program the pcmcia interface, while on my board there is not the SA1110
>> > companion chip.
>> >
>> > In the assabet driver the CF is programmed also by writing on the BCR
>> > register of the SA1110, in particular the interesting instruction is:
>> >
>> >  assabet_BCR(SA1110_BCR_CF_POWER |
>> >                         SA1110_BCR_CF_RESET |
>> >                         SA1110_BCR_CF_BUS,
>> >                         SA1110_BCR_CF_POWER_ON |
>> >                         SA1110_BCR_CF_RESET_ENABLE |
>> >                         SA1110_BCR_CF_BUS_ON);
>> >
>> > My question is: what's the mean of the SA1110_BCR_CF_BUS flag? Is it a
>> > particular assabet feature or do it perform some actions on the
>> > PCMCIA interface pins that I must be aware?
>>
>> The interface on the SA1110 can be controlled by three different pins.
>>
>>   Power - whether or not Vcc is applied to the bus
>>   Bus   - whether or not the bus drivers are enabled
>>   Reset - whether or not the device is in reset
>>
>> Not all controllers allow for such fine control.  In many cases, the
>> power and bus controls are grouped together.
> 
> Ok, thanks.
> Now I have another question:
> I have to build the add the net package, but I find an error during the
> compilation:
> 
> ecoscvs/ecos/packages-net/net/tcpip/current/src/ecos/support.c:85: #error At
> least one network driver
> framework must be defined!
> 
> I found that the problem is that CYGPKG_NET_DRIVER_FRAMEWORK is missing. How
> must I define it ?

You need to add the 'CYGPKG_IO_ETH_DRIVERS' package.

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

* Re: [ECOS] CF driver
  2001-05-21  9:13     ` Gary Thomas
@ 2001-05-21  9:42       ` Andrea Acquaviva
  0 siblings, 0 replies; 6+ messages in thread
From: Andrea Acquaviva @ 2001-05-21  9:42 UTC (permalink / raw)
  To: Gary Thomas, ecos-discuss

Gary Thomas wrote:

> On 21-May-2001 Andrea Acquaviva wrote:
> > Gary Thomas wrote:
> >
> >>
> >> On 21-May-2001 Andrea Acquaviva wrote:
> >> > Hi all,
> >> >
> >> > I'm writing an eCos driver for the CF interface on my Strongarm 1100
> >> > based board. I'm modifing the same driver written for the assabet board.
> >> > The main difference is that the assabet driver uses the SA1110 to
> >> > program the pcmcia interface, while on my board there is not the SA1110
> >> > companion chip.
> >> >
> >> > In the assabet driver the CF is programmed also by writing on the BCR
> >> > register of the SA1110, in particular the interesting instruction is:
> >> >
> >> >  assabet_BCR(SA1110_BCR_CF_POWER |
> >> >                         SA1110_BCR_CF_RESET |
> >> >                         SA1110_BCR_CF_BUS,
> >> >                         SA1110_BCR_CF_POWER_ON |
> >> >                         SA1110_BCR_CF_RESET_ENABLE |
> >> >                         SA1110_BCR_CF_BUS_ON);
> >> >
> >> > My question is: what's the mean of the SA1110_BCR_CF_BUS flag? Is it a
> >> > particular assabet feature or do it perform some actions on the
> >> > PCMCIA interface pins that I must be aware?
> >>
> >> The interface on the SA1110 can be controlled by three different pins.
> >>
> >>   Power - whether or not Vcc is applied to the bus
> >>   Bus   - whether or not the bus drivers are enabled
> >>   Reset - whether or not the device is in reset
> >>
> >> Not all controllers allow for such fine control.  In many cases, the
> >> power and bus controls are grouped together.
> >
> > Ok, thanks.
> > Now I have another question:
> > I have to build the add the net package, but I find an error during the
> > compilation:
> >
> > ecoscvs/ecos/packages-net/net/tcpip/current/src/ecos/support.c:85: #error At
> > least one network driver
> > framework must be defined!
> >
> > I found that the problem is that CYGPKG_NET_DRIVER_FRAMEWORK is missing. How
> > must I define it ?
>
> You need to add the 'CYGPKG_IO_ETH_DRIVERS' package.

I give the following commands in order to configure the network:

ecosconfig new badge net

ecosconfig add CYGPKG_IO_PCMCIA;
ecosconfig add CYGPKG_DEVS_ETH_CF;

also in ecos.ecc, there is the package:

package -hardware CYGPKG_DEVS_PCMCIA_BADGE current.

The following packages are installed as a consequence of the net option:

package -template CYGPKG_NET current ;
package -template CYGPKG_IO_ETH_DRIVERS current ;

Andrea.

--
Ing. Andrea Acquaviva
D.E.I.S. - Universita' di Bologna
V.le Risorgimento, 2    40136 BOLOGNA (ITALY)
Tel: (+39) 051 20 93787 Fax: (+39) 051 2093786



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

* Re: [ECOS] CF driver
       [not found] <XFMail.20010523084332.gthomas@cambridge.redhat.com>
@ 2001-05-23  8:22 ` Andrea Acquaviva
  0 siblings, 0 replies; 6+ messages in thread
From: Andrea Acquaviva @ 2001-05-23  8:22 UTC (permalink / raw)
  To: Gary Thomas; +Cc: ecos-discuss

Gary Thomas wrote:

> Sorry, but I really can't see what's going wrong here.
>
> What development platform are you using?
> What tools?
> What version of the eCos sources?   anonCVS I hope.
>
> Can you try this (in a separate directory):
>   % ecosconfig new assabet net
>   % ecosconfig add pcmcia cf_eth_drivers
>   % ecosconfig tree
>   % make
>
> This should be equivalent to what you are doing, albeit on another
> platform.  Doing this will test the tools and source setup you have
> so we'll have a better idea of why things don't work for you.
>
> On 21-May-2001 Andrea Acquaviva wrote:
> > Gary Thomas wrote:
> >
> >> On 21-May-2001 Andrea Acquaviva wrote:
> >> > Gary Thomas wrote:
> >> >
> >> >> On 21-May-2001 Andrea Acquaviva wrote:
> >> >> > Gary Thomas wrote:
> >> >> >
> >> >> >>
> >> >> >> On 21-May-2001 Andrea Acquaviva wrote:
> >> >> >> > Hi all,
> >> >> >> >
> >> >> >> > I'm writing an eCos driver for the CF interface on my Strongarm 1100
> >> >> >> > based board. I'm modifing the same driver written for the assabet board.
> >> >> >> > The main difference is that the assabet driver uses the SA1110 to
> >> >> >> > program the pcmcia interface, while on my board there is not the SA1110
> >> >> >> > companion chip.
> >> >> >> >
> >> >> >> > In the assabet driver the CF is programmed also by writing on the BCR
> >> >> >> > register of the SA1110, in particular the interesting instruction is:
> >> >> >> >
> >> >> >> >  assabet_BCR(SA1110_BCR_CF_POWER |
> >> >> >> >                         SA1110_BCR_CF_RESET |
> >> >> >> >                         SA1110_BCR_CF_BUS,
> >> >> >> >                         SA1110_BCR_CF_POWER_ON |
> >> >> >> >                         SA1110_BCR_CF_RESET_ENABLE |
> >> >> >> >                         SA1110_BCR_CF_BUS_ON);
> >> >> >> >
> >> >> >> > My question is: what's the mean of the SA1110_BCR_CF_BUS flag? Is it a
> >> >> >> > particular assabet feature or do it perform some actions on the
> >> >> >> > PCMCIA interface pins that I must be aware?
> >> >> >>
> >> >> >> The interface on the SA1110 can be controlled by three different pins.
> >> >> >>
> >> >> >>   Power - whether or not Vcc is applied to the bus
> >> >> >>   Bus   - whether or not the bus drivers are enabled
> >> >> >>   Reset - whether or not the device is in reset
> >> >> >>
> >> >> >> Not all controllers allow for such fine control.  In many cases, the
> >> >> >> power and bus controls are grouped together.
> >> >> >
> >> >> > Ok, thanks.
> >> >> > Now I have another question:
> >> >> > I have to build the add the net package, but I find an error during the
> >> >> > compilation:
> >> >> >
> >> >> > ecoscvs/ecos/packages-net/net/tcpip/current/src/ecos/support.c:85: #error At
> >> >> > least one network driver
> >> >> > framework must be defined!
> >> >> >
> >> >> > I found that the problem is that CYGPKG_NET_DRIVER_FRAMEWORK is missing. How
> >> >> > must I define it ?
> >> >>
> >> >> You need to add the 'CYGPKG_IO_ETH_DRIVERS' package.
> >> >
> >> > I give the following commands in order to configure the network:
> >> >
> >> > ecosconfig new badge net
> >> >
> >> > ecosconfig add CYGPKG_IO_PCMCIA;
> >> > ecosconfig add CYGPKG_DEVS_ETH_CF;
> >> >
> >> > also in ecos.ecc, there is the package:
> >> >
> >> > package -hardware CYGPKG_DEVS_PCMCIA_BADGE current.
> >> >
> >> > The following packages are installed as a consequence of the net option:
> >> >
> >> > package -template CYGPKG_NET current ;
> >> > package -template CYGPKG_IO_ETH_DRIVERS current ;
> >> >
> >>
> >> I'm not sure I see why this fails.  Can you send me your 'ecos.ecc' file?
> >>
> >> Note: send it to me directly as it is quite large and not useful for
> >> the discussion list.
> >
> > Thanks for your help.
> >
> > Andrea.
> >
> >
> > --
> > Ing. Andrea Acquaviva
> > D.E.I.S. - Universita' di Bologna
> > V.le Risorgimento, 2    40136 BOLOGNA (ITALY)
> > Tel: (+39) 051 20 93787 Fax: (+39) 051 2093786
> >
> >

Hi,

Just today I found that by manually adding the implementation description in the
interface (in pcmcia_badge.cdl) fix the problem:


cdl_package CYGPKG_DEVS_PCMCIA_BADGE {
    display       "SA11x0/Badge PCMCIA support"

    parent        CYGPKG_IO_PCMCIA
    active_if     CYGPKG_IO_PCMCIA
    active_if     CYGPKG_HAL_ARM_SA11X0_BADGE

    implements    CYGHWR_IO_PCMCIA_DEVICE

--->    implements    CYGPKG_NET_DRIVER_FRAMEWORK

    include_dir   .
    include_files ; # none _exported_ whatsoever
    description   "PCMCIA (Compact Flash) device support for SA11x0/Badge"
    compile       badge_pcmcia.c
}

As a result, in the ecos.ecc I found:

cdl_interface CYGPKG_NET_DRIVER_FRAMEWORK {
    # Implemented by CYGPKG_DEVS_PCMCIA_BADGE, active, enabled
    # This value cannot be modified here.
    # Flavor: data
    # Current_value: 1

    # The following properties are affected by this value
};

I tried as you suggested and for the assabet target everything works correctly. In
effect, the interface
CYGPKG_NET_DRIVER_FRAMEWORK doesn't exist in ecos.ecc, so it is no necessary to modify
the corresponding pcmcia_assabet.cdl.

Thanks for your help,
Andrea.



--
Ing. Andrea Acquaviva
D.E.I.S. - Universita' di Bologna
V.le Risorgimento, 2    40136 BOLOGNA (ITALY)
Tel: (+39) 051 20 93787 Fax: (+39) 051 2093786



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

end of thread, other threads:[~2001-05-23  8:22 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-05-21  3:53 [ECOS] CF driver Andrea Acquaviva
2001-05-21  7:03 ` Gary Thomas
2001-05-21  9:02   ` Andrea Acquaviva
2001-05-21  9:13     ` Gary Thomas
2001-05-21  9:42       ` Andrea Acquaviva
     [not found] <XFMail.20010523084332.gthomas@cambridge.redhat.com>
2001-05-23  8:22 ` Andrea Acquaviva

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 read-only IMAP folder(s) and NNTP newsgroup(s).