This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
RE: code optimizations
- To: "'Trenton D. Adams'" <tadams at extremeeng dot com>,"'eCos Discussion'" <ecos-discuss at sourceware dot cygnus dot com>
- Subject: RE: [ECOS] code optimizations
- From: "Trenton D. Adams" <tadams at theone dot dnsalias dot com>
- Date: Thu, 23 Aug 2001 09:56:48 -0600
Here's my attempt at changing my build options. Will this get the
config tool to actually change my build options if I specify them in the
text boxes? Do I have to remake the project in order for it to work?
cdl_component CYGPKG_DEVS_PCMCIA_EDB7XXX_OPTIONS {
display "PCMCIA Build options"
flavor none
description "
Package specific build options including control over
compiler flags used only in building this package."
cdl_option CYGPKG_DEVS_PCMCIA_EDB7XXX_CFLAGS_ADD {
display "Additional compiler flags"
flavor data
no_define
default_value { "" }
description "
This option modifies the set of compiler flags for
building the eCos edb7xxx pcmcia package. These flags
are used
in addition to the set of global flags."
}
cdl_option CYGPKG_DEVS_PCMCIA_EDB7XXX_CFLAGS_REMOVE {
display "Suppressed compiler flags"
flavor data
no_define
default_value { "" }
description "
This option modifies the set of compiler flags for
building the eCos edb7xxx pcmcia package. These flags
are removed from
the set of global flags if present."
}
}
-----Original Message-----
From: ecos-discuss-owner@sources.redhat.com
[mailto:ecos-discuss-owner@sources.redhat.com] On Behalf Of Trenton D.
Adams
Sent: Thursday, August 23, 2001 9:32 AM
To: 'eCos Discussion'
Subject: [ECOS] code optimizations
Here's some output from my stepping through my pc-controller driver I'm
making. Notice how the code jumps back and forth? This shouldn't
happen should it? My hardware is supposed to be initialized in a
specific order, not jump around. If this occurs during debug, it would
occur during a normal run too, wouldn't it? I know we talked about this
before, but this just seems really weird to me! I never did show anyone
this before so I thought I would give it a try.
How do I make the config tool allow me to specify different compiler
options for my driver? Is it a CDL thing?
195 *(unsigned *)PMPCON |= 0x0002; // +12V DC-DC
converter on
(gdb) next
197 *(unsigned *)SYSCON2 |= SYSCON2_PCMCIA1; // PCMCIA Slot 1
on
(gdb) next
198
(gdb) list
193 *(unsigned *)PEDDR |= 0x02; // +5V on
194 *(unsigned *)PEDR |= 0x02; // +5V on
195 *(unsigned *)PMPCON |= 0x0002; // +12V DC-DC
converter on
196 *(unsigned *)SYSCON1 |= SYSCON1_EXCKEN; // EXPCLK on
197 *(unsigned *)SYSCON2 |= SYSCON2_PCMCIA1; // PCMCIA Slot 1
on
198
199 // Disable byte swapping and notify when 2 slots in fifo are
ready
200 *(unsigned*)PCSICR &=
201 ~(PCSICR_ENDIAN_CONVERSION |
PCSICR_TRANSQUEUE_THRHOLD_CTRL);
202
(gdb) next
201 ~(PCSICR_ENDIAN_CONVERSION |
PCSICR_TRANSQUEUE_THRHOLD_CTRL);
(gdb) next
204 PCPMR_AUTO_POWERDOWN_ON_REMOVAL |
(gdb) next
194 *(unsigned *)PEDR |= 0x02; // +5V on
(gdb) list
189 static int int_init = 0;
190 unsigned long new_state = 0;
191
192 // Initialize the controller
193 *(unsigned *)PEDDR |= 0x02; // +5V on
194 *(unsigned *)PEDR |= 0x02; // +5V on
195 *(unsigned *)PMPCON |= 0x0002; // +12V DC-DC
converter on
196 *(unsigned *)SYSCON1 |= SYSCON1_EXCKEN; // EXPCLK on
197 *(unsigned *)SYSCON2 |= SYSCON2_PCMCIA1; // PCMCIA Slot 1
on
198
(gdb) next
204 PCPMR_AUTO_POWERDOWN_ON_REMOVAL |
(gdb) list
199 // Disable byte swapping and notify when 2 slots in fifo are
ready
200 *(unsigned*)PCSICR &=
201 ~(PCSICR_ENDIAN_CONVERSION |
PCSICR_TRANSQUEUE_THRHOLD_CTRL);
202
203 *(unsigned*)PCPMR |= 0x3<<10 | // weak pull-up
204 PCPMR_AUTO_POWERDOWN_ON_REMOVAL |
205 PCPMR_AUTO_DISABLE_ON_REMOVAL |
206 PCPMR_STANDBY_DISABLE |
207 PCPMR_STANDBY_CARD_ACCESS |
208 PCPMR_PDREQ_GPIO_ENABLE |
(gdb) next
194 *(unsigned *)PEDR |= 0x02; // +5V on
(gdb) next
196 *(unsigned *)SYSCON1 |= SYSCON1_EXCKEN; // EXPCLK on
(gdb) next
195 *(unsigned *)PMPCON |= 0x0002; // +12V DC-DC
converter on
(gdb) next
196 *(unsigned *)SYSCON1 |= SYSCON1_EXCKEN; // EXPCLK on
(gdb) next
195 *(unsigned *)PMPCON |= 0x0002; // +12V DC-DC
converter on
(gdb) next
196 *(unsigned *)SYSCON1 |= SYSCON1_EXCKEN; // EXPCLK on
(gdb) next
189 static int int_init = 0;
(gdb) next
197 *(unsigned *)SYSCON2 |= SYSCON2_PCMCIA1; // PCMCIA Slot 1
on
(gdb) next
212
(gdb) list
207 PCPMR_STANDBY_CARD_ACCESS |
208 PCPMR_PDREQ_GPIO_ENABLE |
209 PCPMR_AUTO_IDLE;
210
211 *(unsigned*)PCCICR |= PCCICR_CARD_RESETOUTPUT_ENABLE;
212
213 cyg_thread_delay (5);
214
215 new_state = *(unsigned*)PCCIILR;
216
(gdb) next
198
(gdb) next
197 *(unsigned *)SYSCON2 |= SYSCON2_PCMCIA1; // PCMCIA Slot 1
on
(gdb) next
198
(gdb) next
212
(gdb) next
201 ~(PCSICR_ENDIAN_CONVERSION |
PCSICR_TRANSQUEUE_THRHOLD_CTRL);
(gdb) next
214
(gdb) next
204 PCPMR_AUTO_POWERDOWN_ON_REMOVAL |
(gdb) next
201 ~(PCSICR_ENDIAN_CONVERSION |
PCSICR_TRANSQUEUE_THRHOLD_CTRL);
(gdb) next
204 PCPMR_AUTO_POWERDOWN_ON_REMOVAL |
(gdb) next
212
(gdb) next
204 PCPMR_AUTO_POWERDOWN_ON_REMOVAL |
(gdb) next
212
(gdb) next
Trenton D. Adams
Extreme Engineering
#17, 6025 - 12 St. SE
Calgary, Alberta, Canada
T2H 2K1
Phone: 403 640 9494 ext-208
Fax: 403 640 9599
http://www.extremeeng.com