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
Kirill Smelkov
linux
Commits
20a8305b
Commit
20a8305b
authored
Jan 18, 2004
by
Andrew Morton
Committed by
Linus Torvalds
Jan 18, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[PATCH] sn: serial update
From: Pat Gefre <pfg@sgi.com> Jesse Barnes <jbarnes@tomahawk.engr.sgi.com>
parent
9c5a4934
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
6 deletions
+11
-6
drivers/char/sn_serial.c
drivers/char/sn_serial.c
+11
-6
No files found.
drivers/char/sn_serial.c
View file @
20a8305b
...
@@ -21,8 +21,9 @@
...
@@ -21,8 +21,9 @@
#include <linux/sysrq.h>
#include <linux/sysrq.h>
#include <linux/circ_buf.h>
#include <linux/circ_buf.h>
#include <linux/serial_reg.h>
#include <linux/serial_reg.h>
#include <asm/uaccess.h>
#include <asm/sn/sn_sal.h>
#include <asm/sn/sn_sal.h>
#include <asm/sn/pci/pciio.h>
/* this is needed for get_console_nasid */
#include <asm/sn/pci/pciio.h>
#include <asm/sn/simulator.h>
#include <asm/sn/simulator.h>
#include <asm/sn/sn2/sn_private.h>
#include <asm/sn/sn2/sn_private.h>
...
@@ -771,7 +772,7 @@ sn_sal_read_proc(char *page, char **start, off_t off, int count,
...
@@ -771,7 +772,7 @@ sn_sal_read_proc(char *page, char **start, off_t off, int count,
off_t
begin
=
0
;
off_t
begin
=
0
;
len
+=
sprintf
(
page
,
"sn_serial: nasid:%d irq:%d tx:%d rx:%d
\n
"
,
len
+=
sprintf
(
page
,
"sn_serial: nasid:%d irq:%d tx:%d rx:%d
\n
"
,
get_console_nasid
(),
sn_sal_irq
,
ia64_sn_
get_console_nasid
(),
sn_sal_irq
,
sn_total_tx_count
,
sn_total_rx_count
);
sn_total_tx_count
,
sn_total_rx_count
);
*
eof
=
1
;
*
eof
=
1
;
...
@@ -813,13 +814,18 @@ sn_sal_switch_to_asynch(void)
...
@@ -813,13 +814,18 @@ sn_sal_switch_to_asynch(void)
{
{
unsigned
long
flags
;
unsigned
long
flags
;
sn_debug_printf
(
"sn_serial: about to switch to asynchronous console
\n
"
);
/* without early_printk, we may be invoked late enough to race
/* without early_printk, we may be invoked late enough to race
* with other cpus doing console IO at this point, however
* with other cpus doing console IO at this point, however
* console interrupts will never be enabled */
* console interrupts will never be enabled */
spin_lock_irqsave
(
&
sn_sal_lock
,
flags
);
spin_lock_irqsave
(
&
sn_sal_lock
,
flags
);
if
(
sn_sal_is_asynch
)
{
spin_unlock_irqrestore
(
&
sn_sal_lock
,
flags
);
return
;
}
sn_debug_printf
(
"sn_serial: switch to asynchronous console
\n
"
);
/* early_printk invocation may have done this for us */
/* early_printk invocation may have done this for us */
if
(
!
sn_func
)
{
if
(
!
sn_func
)
{
if
(
IS_RUNNING_ON_SIMULATOR
())
if
(
IS_RUNNING_ON_SIMULATOR
())
...
@@ -901,8 +907,7 @@ sn_sal_module_init(void)
...
@@ -901,8 +907,7 @@ sn_sal_module_init(void)
/* when this driver is compiled in, the console initialization
/* when this driver is compiled in, the console initialization
* will have already switched us into asynchronous operation
* will have already switched us into asynchronous operation
* before we get here through the module initcalls */
* before we get here through the module initcalls */
if
(
!
sn_sal_is_asynch
)
sn_sal_switch_to_asynch
();
sn_sal_switch_to_asynch
();
/* at this point (module_init) we can try to turn on interrupts */
/* at this point (module_init) we can try to turn on interrupts */
if
(
!
IS_RUNNING_ON_SIMULATOR
())
if
(
!
IS_RUNNING_ON_SIMULATOR
())
...
...
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