Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
R
RIOT
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
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
cm-projects
RIOT
Commits
984077d3
Commit
984077d3
authored
8 years ago
by
Oleg Hahm
Browse files
Options
Downloads
Patches
Plain Diff
cpu: x86: eliminate cppcheck warnings
parent
4219011b
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
cpu/x86/x86_memory.c
+2
-0
2 additions, 0 deletions
cpu/x86/x86_memory.c
cpu/x86/x86_pci.c
+1
-1
1 addition, 1 deletion
cpu/x86/x86_pci.c
cpu/x86/x86_pit.c
+1
-1
1 addition, 1 deletion
cpu/x86/x86_pit.c
with
4 additions
and
2 deletions
cpu/x86/x86_memory.c
+
2
−
0
View file @
984077d3
...
@@ -76,6 +76,8 @@ void x86_init_gdt(void)
...
@@ -76,6 +76,8 @@ void x86_init_gdt(void)
.
limit_16_19_and_flags
=
0
,
.
limit_16_19_and_flags
=
0
,
.
base_24_31
=
0
,
.
base_24_31
=
0
,
},
},
/* cppcheck-suppress duplicateExpression
* it's for consistent look & feel */
[
0x0008
/
8
]
=
{
[
0x0008
/
8
]
=
{
.
limit_0_15
=
0xFFFF
,
.
limit_0_15
=
0xFFFF
,
.
base_0_15
=
0
,
.
base_0_15
=
0
,
...
...
This diff is collapsed.
Click to expand it.
cpu/x86/x86_pci.c
+
1
−
1
View file @
984077d3
...
@@ -181,7 +181,7 @@ static void pci_setup_ios(struct x86_known_pci_device *dev)
...
@@ -181,7 +181,7 @@ static void pci_setup_ios(struct x86_known_pci_device *dev)
printf
(
" BAR %u: memory, physical = 0x%08x-0x%08x, virtual = 0x%08x-0x%08x
\n
"
,
printf
(
" BAR %u: memory, physical = 0x%08x-0x%08x, virtual = 0x%08x-0x%08x
\n
"
,
bar_num
,
bar_num
,
physical_start
,
physical_start
+
length
-
1
,
physical_start
,
physical_start
+
length
-
1
,
(
unsigned
)
ptr
,
(
uintptr_t
)
ptr
+
length
-
1
);
(
unsigned
)
ptr
,
(
unsigned
)
(
(
uintptr_t
)
ptr
+
length
-
1
)
)
;
}
}
}
}
}
}
...
...
This diff is collapsed.
Click to expand it.
cpu/x86/x86_pit.c
+
1
−
1
View file @
984077d3
...
@@ -55,7 +55,7 @@ void x86_pit_set2(unsigned channel, unsigned mode, uint16_t max)
...
@@ -55,7 +55,7 @@ void x86_pit_set2(unsigned channel, unsigned mode, uint16_t max)
{
{
unsigned
old_flags
=
irq_disable
();
unsigned
old_flags
=
irq_disable
();
outb
(
PIT_COMMAND_PORT
,
((
channel
-
1
)
<<
6
)
|
mode
|
PIT_ACCESS_MODE_LO_HI
);
outb
(
PIT_COMMAND_PORT
,
((
channel
-
1
)
<<
6
)
|
mode
|
PIT_ACCESS_MODE_LO_HI
);
outb
(
PIT_CHANNEL_0_PORT
+
channel
-
1
,
max
&
&
0xff
);
outb
(
PIT_CHANNEL_0_PORT
+
channel
-
1
,
max
&
0xff
);
outb
(
PIT_CHANNEL_0_PORT
+
channel
-
1
,
max
>>
8
);
outb
(
PIT_CHANNEL_0_PORT
+
channel
-
1
,
max
>>
8
);
irq_restore
(
old_flags
);
irq_restore
(
old_flags
);
}
}
...
...
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