Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
L
lede-mikrotik
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
External wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Johannes Rudolph
lede-mikrotik
Commits
eb77b370
Commit
eb77b370
authored
17 years ago
by
John Crispin
Browse files
Options
Downloads
Patches
Plain Diff
revert some breakage
SVN-Revision: 10176
parent
31c7a323
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
target/linux/ifxmips/files/arch/mips/ifxmips/prom.c
+3
-10
3 additions, 10 deletions
target/linux/ifxmips/files/arch/mips/ifxmips/prom.c
target/linux/ifxmips/files/include/asm-mips/ifxmips/ifxmips.h
+16
-17
16 additions, 17 deletions
...et/linux/ifxmips/files/include/asm-mips/ifxmips/ifxmips.h
with
19 additions
and
27 deletions
target/linux/ifxmips/files/arch/mips/ifxmips/prom.c
+
3
−
10
View file @
eb77b370
...
...
@@ -29,13 +29,6 @@
#include
<asm/bootinfo.h>
#include
<asm/ifxmips/ifxmips.h>
#ifdef CONFIG_IFXMIPS_USE_CONSOLE0
#define ASC_OFFSET 0
#elif CONFIG_IFXMIPS_USE_CONSOLE1
#define ASC_OFFSET IFXMIPS_ASC1_BASE_OFFSET
#else
#error a tty for the console must be selected
#endif
static
char
buf
[
1024
];
void
...
...
@@ -46,11 +39,11 @@ prom_free_prom_memory (void)
void
prom_putchar
(
char
c
)
{
while
((
readl
(
IFXMIPS_ASC
0
_FSTAT
+
ASC_OFFSET
)
&
ASCFSTAT_TXFFLMASK
)
>>
ASCFSTAT_TXFFLOFF
);
while
((
readl
(
IFXMIPS_ASC
1
_FSTAT
)
&
ASCFSTAT_TXFFLMASK
)
>>
ASCFSTAT_TXFFLOFF
);
if
(
c
==
'\n'
)
writel
(
'\r'
,
IFXMIPS_ASC
0
_TBUF
+
ASC_OFFSET
);
writel
(
c
,
IFXMIPS_ASC
0
_TBUF
+
ASC_OFFSET
);
writel
(
'\r'
,
IFXMIPS_ASC
1
_TBUF
);
writel
(
c
,
IFXMIPS_ASC
1
_TBUF
);
}
void
...
...
This diff is collapsed.
Click to expand it.
target/linux/ifxmips/files/include/asm-mips/ifxmips/ifxmips.h
+
16
−
17
View file @
eb77b370
...
...
@@ -34,18 +34,17 @@
#define IFXMIPS_FLASH_MAX 0x2000000
/*------------ ASC
0
*/
/*------------ ASC
1
*/
#define IFXMIPS_ASC0_BASE_ADDR (KSEG1 + 0x1E400C00)
#define IFXMIPS_ASC1_BASE_OFFSET ((0x1E100C00 - 0x1E400C00) / sizeof(u32))
#define IFXMIPS_ASC1_BASE_ADDR (KSEG1 + 0x1E100C00)
/* FIFO status register */
#define IFXMIPS_ASC
0
_FSTAT ((u32*)(IFXMIPS_ASC
0
_BASE_ADDR + 0x0048))
#define IFXMIPS_ASC
1
_FSTAT ((u32*)(IFXMIPS_ASC
1
_BASE_ADDR + 0x0048))
#define ASCFSTAT_TXFFLMASK 0x3F00
#define ASCFSTAT_TXFFLOFF 8
/* ASC1 transmit buffer */
#define IFXMIPS_ASC
0
_TBUF ((u32*)(IFXMIPS_ASC
0
_BASE_ADDR + 0x0020))
#define IFXMIPS_ASC
1
_TBUF ((u32*)(IFXMIPS_ASC
1
_BASE_ADDR + 0x0020))
/* channel operating modes */
#define ASCOPT_CSIZE 0x3
...
...
@@ -57,43 +56,43 @@
#define ASCOPT_CREAD 0x20
/* hardware modified control register */
#define IFXMIPS_ASC
0
_WHBSTATE ((u32*)(IFXMIPS_ASC
0
_BASE_ADDR + 0x0018))
#define IFXMIPS_ASC
1
_WHBSTATE ((u32*)(IFXMIPS_ASC
1
_BASE_ADDR + 0x0018))
/* receive buffer register */
#define IFXMIPS_ASC
0
_RBUF ((u32*)(IFXMIPS_ASC
0
_BASE_ADDR + 0x0024))
#define IFXMIPS_ASC
1
_RBUF ((u32*)(IFXMIPS_ASC
1
_BASE_ADDR + 0x0024))
/* status register */
#define IFXMIPS_ASC
0
_STATE ((u32*)(IFXMIPS_ASC
0
_BASE_ADDR + 0x0014))
#define IFXMIPS_ASC
1
_STATE ((u32*)(IFXMIPS_ASC
1
_BASE_ADDR + 0x0014))
/* interrupt control */
#define IFXMIPS_ASC
0
_IRNCR ((u32*)(IFXMIPS_ASC
0
_BASE_ADDR + 0x00F8))
#define IFXMIPS_ASC
1
_IRNCR ((u32*)(IFXMIPS_ASC
1
_BASE_ADDR + 0x00F8))
#define ASC_IRNCR_TIR 0x4
#define ASC_IRNCR_RIR 0x2
#define ASC_IRNCR_EIR 0x4
/* clock control */
#define IFXMIPS_ASC
0
_CLC ((u32*)(IFXMIPS_ASC
0
_BASE_ADDR + 0x0000))
#define IFXMIPS_ASC
1
_CLC ((u32*)(IFXMIPS_ASC
1
_BASE_ADDR + 0x0000))
#define IFXMIPS_ASC
0
_CLC_DISS 0x2
#define IFXMIPS_ASC
1
_CLC_DISS 0x2
/* port input select register */
#define IFXMIPS_ASC
0
_PISEL ((u32*)(IFXMIPS_ASC
0
_BASE_ADDR + 0x0004))
#define IFXMIPS_ASC
1
_PISEL ((u32*)(IFXMIPS_ASC
1
_BASE_ADDR + 0x0004))
/* tx fifo */
#define IFXMIPS_ASC
0
_TXFCON ((u32*)(IFXMIPS_ASC
0
_BASE_ADDR + 0x0044))
#define IFXMIPS_ASC
1
_TXFCON ((u32*)(IFXMIPS_ASC
1
_BASE_ADDR + 0x0044))
/* rx fifo */
#define IFXMIPS_ASC
0
_RXFCON ((u32*)(IFXMIPS_ASC
0
_BASE_ADDR + 0x0040))
#define IFXMIPS_ASC
1
_RXFCON ((u32*)(IFXMIPS_ASC
1
_BASE_ADDR + 0x0040))
/* control */
#define IFXMIPS_ASC
0
_CON ((u32*)(IFXMIPS_ASC
0
_BASE_ADDR + 0x0010))
#define IFXMIPS_ASC
1
_CON ((u32*)(IFXMIPS_ASC
1
_BASE_ADDR + 0x0010))
/* timer reload */
#define IFXMIPS_ASC
0
_BG ((u32*)(IFXMIPS_ASC
0
_BASE_ADDR + 0x0050))
#define IFXMIPS_ASC
1
_BG ((u32*)(IFXMIPS_ASC
1
_BASE_ADDR + 0x0050))
/* int enable */
#define IFXMIPS_ASC
0
_IRNREN ((u32*)(IFXMIPS_ASC
0
_BASE_ADDR + 0x00F4))
#define IFXMIPS_ASC
1
_IRNREN ((u32*)(IFXMIPS_ASC
1
_BASE_ADDR + 0x00F4))
#define ASC_IRNREN_RX_BUF 0x8
#define ASC_IRNREN_TX_BUF 0x4
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment