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
c708508c
Commit
c708508c
authored
Mar 28, 2003
by
David S. Miller
Browse files
Options
Browse Files
Download
Plain Diff
Merge nuts.ninka.net:/home/davem/src/BK/sparcwork-2.5
into nuts.ninka.net:/home/davem/src/BK/sparc-2.5
parents
edad54dc
306eb7e6
Changes
6
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
91 additions
and
7 deletions
+91
-7
arch/sparc64/kernel/irq.c
arch/sparc64/kernel/irq.c
+3
-3
arch/sparc64/kernel/pci.c
arch/sparc64/kernel/pci.c
+69
-0
arch/sparc64/kernel/rtrap.S
arch/sparc64/kernel/rtrap.S
+2
-0
arch/sparc64/kernel/traps.c
arch/sparc64/kernel/traps.c
+12
-0
drivers/usb/host/ohci-pci.c
drivers/usb/host/ohci-pci.c
+1
-1
include/asm-sparc64/pci.h
include/asm-sparc64/pci.h
+4
-3
No files found.
arch/sparc64/kernel/irq.c
View file @
c708508c
...
...
@@ -356,7 +356,7 @@ int request_irq(unsigned int irq, void (*handler)(int, void *, struct pt_regs *)
}
if
(
action
==
NULL
)
action
=
(
struct
irqaction
*
)
kmalloc
(
sizeof
(
struct
irqaction
),
GFP_
KERNEL
);
GFP_
ATOMIC
);
if
(
!
action
)
{
spin_unlock_irqrestore
(
&
irq_action_lock
,
flags
);
...
...
@@ -376,7 +376,7 @@ int request_irq(unsigned int irq, void (*handler)(int, void *, struct pt_regs *)
goto
free_and_ebusy
;
}
if
((
bucket
->
flags
&
IBF_MULTI
)
==
0
)
{
vector
=
kmalloc
(
sizeof
(
void
*
)
*
4
,
GFP_
KERNEL
);
vector
=
kmalloc
(
sizeof
(
void
*
)
*
4
,
GFP_
ATOMIC
);
if
(
vector
==
NULL
)
goto
free_and_enomem
;
...
...
@@ -900,7 +900,7 @@ int request_fast_irq(unsigned int irq,
}
if
(
action
==
NULL
)
action
=
(
struct
irqaction
*
)
kmalloc
(
sizeof
(
struct
irqaction
),
GFP_
KERNEL
);
GFP_
ATOMIC
);
if
(
!
action
)
{
spin_unlock_irqrestore
(
&
irq_action_lock
,
flags
);
return
-
ENOMEM
;
...
...
arch/sparc64/kernel/pci.c
View file @
c708508c
...
...
@@ -470,6 +470,54 @@ int pci_assign_resource(struct pci_dev *pdev, int resource)
return
err
;
}
/* Sort resources by alignment */
void
pdev_sort_resources
(
struct
pci_dev
*
dev
,
struct
resource_list
*
head
)
{
int
i
;
for
(
i
=
0
;
i
<
PCI_NUM_RESOURCES
;
i
++
)
{
struct
resource
*
r
;
struct
resource_list
*
list
,
*
tmp
;
unsigned
long
r_align
;
r
=
&
dev
->
resource
[
i
];
r_align
=
r
->
end
-
r
->
start
;
if
(
!
(
r
->
flags
)
||
r
->
parent
)
continue
;
if
(
!
r_align
)
{
printk
(
KERN_WARNING
"PCI: Ignore bogus resource %d "
"[%lx:%lx] of %s
\n
"
,
i
,
r
->
start
,
r
->
end
,
dev
->
dev
.
name
);
continue
;
}
r_align
=
(
i
<
PCI_BRIDGE_RESOURCES
)
?
r_align
+
1
:
r
->
start
;
for
(
list
=
head
;
;
list
=
list
->
next
)
{
unsigned
long
align
=
0
;
struct
resource_list
*
ln
=
list
->
next
;
int
idx
;
if
(
ln
)
{
idx
=
ln
->
res
-
&
ln
->
dev
->
resource
[
0
];
align
=
(
idx
<
PCI_BRIDGE_RESOURCES
)
?
ln
->
res
->
end
-
ln
->
res
->
start
+
1
:
ln
->
res
->
start
;
}
if
(
r_align
>
align
)
{
tmp
=
kmalloc
(
sizeof
(
*
tmp
),
GFP_KERNEL
);
if
(
!
tmp
)
panic
(
"pdev_sort_resources(): "
"kmalloc() failed!
\n
"
);
tmp
->
next
=
ln
;
tmp
->
res
=
r
;
tmp
->
dev
=
dev
;
list
->
next
=
tmp
;
break
;
}
}
}
}
void
pcibios_update_irq
(
struct
pci_dev
*
pdev
,
int
irq
)
{
}
...
...
@@ -484,6 +532,27 @@ int pcibios_enable_device(struct pci_dev *pdev, int mask)
return
0
;
}
void
pcibios_resource_to_bus
(
struct
pci_dev
*
pdev
,
struct
pci_bus_region
*
region
,
struct
resource
*
res
)
{
struct
pci_pbm_info
*
pbm
=
pci_bus2pbm
[
pdev
->
bus
->
number
];
struct
resource
zero_res
,
*
root
;
zero_res
.
start
=
0
;
zero_res
.
end
=
0
;
zero_res
.
flags
=
res
->
flags
;
if
(
res
->
flags
&
IORESOURCE_IO
)
root
=
&
pbm
->
io_space
;
else
root
=
&
pbm
->
mem_space
;
pbm
->
parent
->
resource_adjust
(
pdev
,
&
zero_res
,
root
);
region
->
start
=
res
->
start
-
zero_res
.
start
;
region
->
end
=
res
->
end
-
zero_res
.
start
;
}
char
*
__init
pcibios_setup
(
char
*
str
)
{
if
(
!
strcmp
(
str
,
"onboardfirst"
))
{
...
...
arch/sparc64/kernel/rtrap.S
View file @
c708508c
...
...
@@ -185,6 +185,7 @@ rtrap_xcall:
*
sched
+
signal
checks
with
IRQs
disabled
.
*/
to_user
:
wrpr
%
g0
,
RTRAP_PSTATE_IRQOFF
,
%
pstate
wrpr
0
,
%
pil
__handle_preemption_continue
:
ldx
[%
g6
+
TI_FLAGS
],
%
l0
sethi
%
hi
(
_TIF_USER_WORK_MASK
),
%
o0
...
...
@@ -271,6 +272,7 @@ to_kernel:
brnz
%
l5
,
kern_fpucheck
sethi
%
hi
(
PREEMPT_ACTIVE
),
%
l6
stw
%
l6
,
[%
g6
+
TI_PRE_COUNT
]
wrpr
0
,
%
pil
call
schedule
nop
ba
,
pt
%
xcc
,
rtrap
...
...
arch/sparc64/kernel/traps.c
View file @
c708508c
...
...
@@ -1575,6 +1575,9 @@ void show_trace_raw(struct thread_info *tp, unsigned long ksp)
struct
reg_window
*
rw
;
int
count
=
0
;
if
(
tp
==
current_thread_info
())
flushw_all
();
fp
=
ksp
+
STACK_BIAS
;
thread_base
=
(
unsigned
long
)
tp
;
do
{
...
...
@@ -1597,6 +1600,15 @@ void show_trace_task(struct task_struct *tsk)
tsk
->
thread_info
->
ksp
);
}
void
dump_stack
(
void
)
{
unsigned
long
ksp
;
__asm__
__volatile__
(
"mov %%fp, %0"
:
"=r"
(
ksp
));
show_trace_raw
(
current_thread_info
(),
ksp
);
}
void
die_if_kernel
(
char
*
str
,
struct
pt_regs
*
regs
)
{
static
int
die_counter
;
...
...
drivers/usb/host/ohci-pci.c
View file @
c708508c
...
...
@@ -389,7 +389,7 @@ static int __init ohci_hcd_pci_init (void)
if
(
usb_disabled
())
return
-
ENODEV
;
printk
(
KERN_DEBUG
"%s: block sizes: ed %
d td %
d
\n
"
,
hcd_name
,
printk
(
KERN_DEBUG
"%s: block sizes: ed %
Zd td %Z
d
\n
"
,
hcd_name
,
sizeof
(
struct
ed
),
sizeof
(
struct
td
));
return
pci_module_init
(
&
ohci_pci_driver
);
}
...
...
include/asm-sparc64/pci.h
View file @
c708508c
...
...
@@ -205,9 +205,10 @@ extern int pci_mmap_page_range(struct pci_dev *dev, struct vm_area_struct *vma,
#define HAVE_ARCH_PCI_MWI
extern
int
pcibios_prep_mwi
(
struct
pci_dev
*
dev
);
#endif
/* __KERNEL__ */
extern
void
pcibios_resource_to_bus
(
struct
pci_dev
*
dev
,
struct
pci_bus_region
*
region
,
struct
resource
*
res
);
/* generic pci stuff */
#include <asm-generic/pci.h>
#endif
/* __KERNEL__ */
#endif
/* __SPARC64_PCI_H */
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