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
77089c52
Commit
77089c52
authored
Sep 17, 2017
by
Helge Deller
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
parisc: Add wrapper for pdc_instr() firmware function
Signed-off-by:
Helge Deller
<
deller@gmx.de
>
parent
08b8a99b
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
21 additions
and
0 deletions
+21
-0
arch/parisc/include/asm/pdc.h
arch/parisc/include/asm/pdc.h
+1
-0
arch/parisc/kernel/firmware.c
arch/parisc/kernel/firmware.c
+20
-0
No files found.
arch/parisc/include/asm/pdc.h
View file @
77089c52
...
...
@@ -280,6 +280,7 @@ void setup_pdc(void); /* in inventory.c */
/* wrapper-functions from pdc.c */
int
pdc_add_valid
(
unsigned
long
address
);
int
pdc_instr
(
unsigned
int
*
instr
);
int
pdc_chassis_info
(
struct
pdc_chassis_info
*
chassis_info
,
void
*
led_info
,
unsigned
long
len
);
int
pdc_chassis_disp
(
unsigned
long
disp
);
int
pdc_chassis_warn
(
unsigned
long
*
warn
);
...
...
arch/parisc/kernel/firmware.c
View file @
77089c52
...
...
@@ -232,6 +232,26 @@ int pdc_add_valid(unsigned long address)
}
EXPORT_SYMBOL
(
pdc_add_valid
);
/**
* pdc_instr - Get instruction that invokes PDCE_CHECK in HPMC handler.
* @instr: Pointer to variable which will get instruction opcode.
*
* The return value is PDC_OK (0) in case call succeeded.
*/
int
__init
pdc_instr
(
unsigned
int
*
instr
)
{
int
retval
;
unsigned
long
flags
;
spin_lock_irqsave
(
&
pdc_lock
,
flags
);
retval
=
mem_pdc_call
(
PDC_INSTR
,
0UL
,
__pa
(
pdc_result
));
convert_to_wide
(
pdc_result
);
*
instr
=
pdc_result
[
0
];
spin_unlock_irqrestore
(
&
pdc_lock
,
flags
);
return
retval
;
}
/**
* pdc_chassis_info - Return chassis information.
* @result: The return buffer.
...
...
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