Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
3eec4b93
Commit
3eec4b93
authored
Jul 30, 2004
by
Linus Torvalds
Browse files
Options
Browse Files
Download
Plain Diff
Merge
http://lia64.bkbits.net/to-base-2.6
into ppc970.osdl.org:/home/torvalds/v2.6/linux
parents
223e5b74
8e61b243
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
28 additions
and
19 deletions
+28
-19
arch/ia64/sn/io/sn2/bte_error.c
arch/ia64/sn/io/sn2/bte_error.c
+9
-0
arch/ia64/sn/kernel/bte.c
arch/ia64/sn/kernel/bte.c
+4
-7
drivers/serial/sn_console.c
drivers/serial/sn_console.c
+15
-12
No files found.
arch/ia64/sn/io/sn2/bte_error.c
View file @
3eec4b93
...
@@ -90,6 +90,7 @@ bte_error_handler(unsigned long _nodepda)
...
@@ -90,6 +90,7 @@ bte_error_handler(unsigned long _nodepda)
ii_icrb0_d_u_t
icrbd
;
/* II CRB Register D */
ii_icrb0_d_u_t
icrbd
;
/* II CRB Register D */
ii_ibcr_u_t
ibcr
;
ii_ibcr_u_t
ibcr
;
ii_icmr_u_t
icmr
;
ii_icmr_u_t
icmr
;
ii_ieclr_u_t
ieclr
;
BTE_PRINTK
((
"bte_error_handler(%p) - %d
\n
"
,
err_nodepda
,
BTE_PRINTK
((
"bte_error_handler(%p) - %d
\n
"
,
err_nodepda
,
...
@@ -177,6 +178,14 @@ bte_error_handler(unsigned long _nodepda)
...
@@ -177,6 +178,14 @@ bte_error_handler(unsigned long _nodepda)
imem
.
ii_imem_fld_s
.
i_b0_esd
=
imem
.
ii_imem_fld_s
.
i_b1_esd
=
1
;
imem
.
ii_imem_fld_s
.
i_b0_esd
=
imem
.
ii_imem_fld_s
.
i_b1_esd
=
1
;
REMOTE_HUB_S
(
nasid
,
IIO_IMEM
,
imem
.
ii_imem_regval
);
REMOTE_HUB_S
(
nasid
,
IIO_IMEM
,
imem
.
ii_imem_regval
);
/* Clear IBLS0/1 error bits */
ieclr
.
ii_ieclr_regval
=
0
;
if
(
err_nodepda
->
bte_if
[
0
].
bh_error
!=
BTE_SUCCESS
)
ieclr
.
ii_ieclr_fld_s
.
i_e_bte_0
=
1
;
if
(
err_nodepda
->
bte_if
[
1
].
bh_error
!=
BTE_SUCCESS
)
ieclr
.
ii_ieclr_fld_s
.
i_e_bte_1
=
1
;
REMOTE_HUB_S
(
nasid
,
IIO_IECLR
,
ieclr
.
ii_ieclr_regval
);
/* Reinitialize both BTE state machines. */
/* Reinitialize both BTE state machines. */
ibcr
.
ii_ibcr_regval
=
REMOTE_HUB_L
(
nasid
,
IIO_IBCR
);
ibcr
.
ii_ibcr_regval
=
REMOTE_HUB_L
(
nasid
,
IIO_IBCR
);
ibcr
.
ii_ibcr_fld_s
.
i_soft_reset
=
1
;
ibcr
.
ii_ibcr_fld_s
.
i_soft_reset
=
1
;
...
...
arch/ia64/sn/kernel/bte.c
View file @
3eec4b93
...
@@ -16,7 +16,6 @@
...
@@ -16,7 +16,6 @@
#include <asm/sn/pda.h>
#include <asm/sn/pda.h>
#include <asm/sn/sn2/shubio.h>
#include <asm/sn/sn2/shubio.h>
#include <asm/nodedata.h>
#include <asm/nodedata.h>
#include <asm/delay.h>
#include <linux/bootmem.h>
#include <linux/bootmem.h>
#include <linux/string.h>
#include <linux/string.h>
...
@@ -71,6 +70,7 @@ bte_result_t
...
@@ -71,6 +70,7 @@ bte_result_t
bte_copy
(
u64
src
,
u64
dest
,
u64
len
,
u64
mode
,
void
*
notification
)
bte_copy
(
u64
src
,
u64
dest
,
u64
len
,
u64
mode
,
void
*
notification
)
{
{
u64
transfer_size
;
u64
transfer_size
;
u64
transfer_stat
;
struct
bteinfo_s
*
bte
;
struct
bteinfo_s
*
bte
;
bte_result_t
bte_status
;
bte_result_t
bte_status
;
unsigned
long
irq_flags
;
unsigned
long
irq_flags
;
...
@@ -148,9 +148,6 @@ bte_copy(u64 src, u64 dest, u64 len, u64 mode, void *notification)
...
@@ -148,9 +148,6 @@ bte_copy(u64 src, u64 dest, u64 len, u64 mode, void *notification)
if
(
!
(
mode
&
BTE_WACQUIRE
))
{
if
(
!
(
mode
&
BTE_WACQUIRE
))
{
return
BTEFAIL_NOTAVAIL
;
return
BTEFAIL_NOTAVAIL
;
}
}
/* Wait until a bte is available. */
udelay
(
1
);
}
while
(
1
);
}
while
(
1
);
...
@@ -194,15 +191,15 @@ bte_copy(u64 src, u64 dest, u64 len, u64 mode, void *notification)
...
@@ -194,15 +191,15 @@ bte_copy(u64 src, u64 dest, u64 len, u64 mode, void *notification)
return
BTE_SUCCESS
;
return
BTE_SUCCESS
;
}
}
while
(
*
bte
->
most_rcnt_na
==
-
1UL
)
{
while
(
(
transfer_stat
=
*
bte
->
most_rcnt_na
)
==
-
1UL
)
{
}
}
BTE_PRINTKV
((
" Delay Done. IBLS = 0x%lx, most_rcnt_na = 0x%lx
\n
"
,
BTE_PRINTKV
((
" Delay Done. IBLS = 0x%lx, most_rcnt_na = 0x%lx
\n
"
,
BTE_LNSTAT_LOAD
(
bte
),
*
bte
->
most_rcnt_na
));
BTE_LNSTAT_LOAD
(
bte
),
*
bte
->
most_rcnt_na
));
if
(
*
bte
->
most_rcnt_na
&
IBLS_ERROR
)
{
if
(
transfer_stat
&
IBLS_ERROR
)
{
bte_status
=
*
bte
->
most_rcnt_na
&
~
IBLS_ERROR
;
bte_status
=
transfer_stat
&
~
IBLS_ERROR
;
*
bte
->
most_rcnt_na
=
0L
;
*
bte
->
most_rcnt_na
=
0L
;
}
else
{
}
else
{
bte_status
=
BTE_SUCCESS
;
bte_status
=
BTE_SUCCESS
;
...
...
drivers/serial/sn_console.c
View file @
3eec4b93
...
@@ -105,10 +105,9 @@ static struct miscdevice misc; /* used with misc_register for dynamic */
...
@@ -105,10 +105,9 @@ static struct miscdevice misc; /* used with misc_register for dynamic */
extern
u64
master_node_bedrock_address
;
extern
u64
master_node_bedrock_address
;
extern
void
early_sn_setup
(
void
);
extern
void
early_sn_setup
(
void
);
static
int
sn_debug_printf
(
const
char
*
fmt
,
...);
#undef DEBUG
#undef DEBUG
#ifdef DEBUG
#ifdef DEBUG
static
int
sn_debug_printf
(
const
char
*
fmt
,
...);
#define DPRINTF(x...) sn_debug_printf(x)
#define DPRINTF(x...) sn_debug_printf(x)
#else
#else
#define DPRINTF(x...) do { } while (0)
#define DPRINTF(x...) do { } while (0)
...
@@ -489,6 +488,8 @@ static struct uart_ops sn_console_ops = {
...
@@ -489,6 +488,8 @@ static struct uart_ops sn_console_ops = {
/* End of uart struct functions and defines */
/* End of uart struct functions and defines */
#ifdef DEBUG
/**
/**
* sn_debug_printf - close to hardware debugging printf
* sn_debug_printf - close to hardware debugging printf
* @fmt: printf format
* @fmt: printf format
...
@@ -520,6 +521,7 @@ sn_debug_printf(const char *fmt, ...)
...
@@ -520,6 +521,7 @@ sn_debug_printf(const char *fmt, ...)
va_end
(
args
);
va_end
(
args
);
return
printed_len
;
return
printed_len
;
}
}
#endif
/* DEBUG */
/*
/*
* Interrupt handling routines.
* Interrupt handling routines.
...
@@ -654,7 +656,7 @@ sn_transmit_chars(struct sn_cons_port *port, int raw)
...
@@ -654,7 +656,7 @@ sn_transmit_chars(struct sn_cons_port *port, int raw)
port
->
sc_ops
->
sal_puts
(
start
,
xmit_count
);
port
->
sc_ops
->
sal_puts
(
start
,
xmit_count
);
#ifdef DEBUG
#ifdef DEBUG
if
(
!
result
)
if
(
!
result
)
sn_debug_printf
(
"`"
);
DPRINTF
(
"`"
);
#endif
#endif
if
(
result
>
0
)
{
if
(
result
>
0
)
{
xmit_count
-=
result
;
xmit_count
-=
result
;
...
@@ -971,6 +973,7 @@ module_exit(sn_sal_module_exit);
...
@@ -971,6 +973,7 @@ module_exit(sn_sal_module_exit);
/**
/**
* puts_raw_fixed - sn_sal_console_write helper for adding \r's as required
* puts_raw_fixed - sn_sal_console_write helper for adding \r's as required
* @puts_raw : puts function to do the writing
* @s: input string
* @s: input string
* @count: length
* @count: length
*
*
...
@@ -978,19 +981,19 @@ module_exit(sn_sal_module_exit);
...
@@ -978,19 +981,19 @@ module_exit(sn_sal_module_exit);
* ia64_sn_console_putb (what sal_puts_raw below actually does).
* ia64_sn_console_putb (what sal_puts_raw below actually does).
*
*
*/
*/
static
void
puts_raw_fixed
(
const
char
*
s
,
int
count
)
static
void
puts_raw_fixed
(
int
(
*
puts_raw
)
(
const
char
*
s
,
int
len
),
const
char
*
s
,
int
count
)
{
{
const
char
*
s1
;
const
char
*
s1
;
struct
sn_cons_port
*
port
=
&
sal_console_port
;
/* Output '\r' before each '\n' */
/* Output '\r' before each '\n' */
while
((
s1
=
memchr
(
s
,
'\n'
,
count
))
!=
NULL
)
{
while
((
s1
=
memchr
(
s
,
'\n'
,
count
))
!=
NULL
)
{
p
ort
->
sc_ops
->
sal_p
uts_raw
(
s
,
s1
-
s
);
puts_raw
(
s
,
s1
-
s
);
p
ort
->
sc_ops
->
sal_p
uts_raw
(
"
\r\n
"
,
2
);
puts_raw
(
"
\r\n
"
,
2
);
count
-=
s1
+
1
-
s
;
count
-=
s1
+
1
-
s
;
s
=
s1
+
1
;
s
=
s1
+
1
;
}
}
p
ort
->
sc_ops
->
sal_p
uts_raw
(
s
,
count
);
puts_raw
(
s
,
count
);
}
}
/**
/**
...
@@ -1072,7 +1075,7 @@ sn_sal_console_write(struct console *co, const char *s, unsigned count)
...
@@ -1072,7 +1075,7 @@ sn_sal_console_write(struct console *co, const char *s, unsigned count)
/* fell thru */
/* fell thru */
stole_lock
=
1
;
stole_lock
=
1
;
}
}
puts_raw_fixed
(
s
,
count
);
puts_raw_fixed
(
port
->
sc_ops
->
sal_puts_raw
,
s
,
count
);
}
}
else
{
else
{
stole_lock
=
0
;
stole_lock
=
0
;
...
@@ -1081,12 +1084,12 @@ sn_sal_console_write(struct console *co, const char *s, unsigned count)
...
@@ -1081,12 +1084,12 @@ sn_sal_console_write(struct console *co, const char *s, unsigned count)
sn_transmit_chars
(
port
,
1
);
sn_transmit_chars
(
port
,
1
);
spin_unlock_irqrestore
(
&
port
->
sc_port
.
lock
,
flags
);
spin_unlock_irqrestore
(
&
port
->
sc_port
.
lock
,
flags
);
puts_raw_fixed
(
s
,
count
);
puts_raw_fixed
(
port
->
sc_ops
->
sal_puts_raw
,
s
,
count
);
}
}
}
}
else
{
else
{
/* Not yet registered with serial core - simple case */
/* Not yet registered with serial core - simple case */
puts_raw_fixed
(
s
,
count
);
puts_raw_fixed
(
port
->
sc_ops
->
sal_puts_raw
,
s
,
count
);
}
}
}
}
...
@@ -1123,7 +1126,7 @@ sn_sal_console_setup(struct console *co, char *options)
...
@@ -1123,7 +1126,7 @@ sn_sal_console_setup(struct console *co, char *options)
static
void
__init
static
void
__init
sn_sal_console_write_early
(
struct
console
*
co
,
const
char
*
s
,
unsigned
count
)
sn_sal_console_write_early
(
struct
console
*
co
,
const
char
*
s
,
unsigned
count
)
{
{
sal_console_port
.
sc_ops
->
sal_puts
(
s
,
count
);
puts_raw_fixed
(
sal_console_port
.
sc_ops
->
sal_puts_raw
,
s
,
count
);
}
}
/* Used for very early console printing - again, before
/* Used for very early console printing - again, before
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment