[SerialICE] Patch set updated for serialice: 971281b Drop io_base_post
Kyösti Mälkki (kyosti.malkki@gmail.com)
gerrit at coreboot.org
Mon Feb 25 18:57:38 CET 2013
Kyösti Mälkki (kyosti.malkki at gmail.com) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/2507
-gerrit
commit 971281b462bb486bc44eaa71df7512eaf4604347
Author: Kyösti Mälkki <kyosti.malkki at gmail.com>
Date: Mon Feb 25 14:50:06 2013 +0200
Drop io_base_post
Add a field .decode in filter to control if it operates on
a set of fixed addresses or a range.
Change-Id: I56a1403dcd0fd887dec6ff9cb3b2b603ed1ce285
Signed-off-by: Kyösti Mälkki <kyosti.malkki at gmail.com>
---
SerialICE/simba/core_io.lua | 27 ++++++++++++++-------------
SerialICE/simba/hooks.lua | 3 ++-
2 files changed, 16 insertions(+), 14 deletions(-)
diff --git a/SerialICE/simba/core_io.lua b/SerialICE/simba/core_io.lua
index 4234239..5781b5a 100644
--- a/SerialICE/simba/core_io.lua
+++ b/SerialICE/simba/core_io.lua
@@ -13,19 +13,19 @@ function io_undefined(f, action)
end
function io_post(f, action)
- if (action.write) then
- printk(f, action, "out%s %04x <= %s\n", size_suffix(action.size), action.addr, size_data(action.size, action.data))
- else
- printk(f, action, " in%s %04x => %s\n", size_suffix(action.size), action.addr, size_data(action.size, action.data))
- end
- return true
-end
-
-function io_base_post(f, action)
- if (action.write) then
- printk(f, action, "[%04x] <= %s\n", action.addr - f.base, size_data(action.size, action.data))
- else
- printk(f, action, "[%04x] => %s\n", action.addr - f.base, size_data(action.size, action.data))
+ local size = size_data(action.size, action.data)
+ if not f.decode or f.decode == F_FIXED then
+ if (action.write) then
+ printk(f, action, "out%s %04x <= %s\n", size_suffix(action.size), action.addr, size)
+ else
+ printk(f, action, " in%s %04x => %s\n", size_suffix(action.size), action.addr, size)
+ end
+ elseif f.decode == F_RANGE then
+ if (action.write) then
+ printk(f, action, "[%04x] <= %s\n", action.addr - f.base, size)
+ else
+ printk(f, action, "[%04x] => %s\n", action.addr - f.base, size)
+ end
end
return true
end
@@ -35,6 +35,7 @@ filter_io_fallback = {
name = "IO",
pre = io_undefined,
post = io_post,
+ decode = F_FIXED,
base = 0x0,
size = 0x10000,
}
diff --git a/SerialICE/simba/hooks.lua b/SerialICE/simba/hooks.lua
index c7cc736..29f574a 100644
--- a/SerialICE/simba/hooks.lua
+++ b/SerialICE/simba/hooks.lua
@@ -149,7 +149,8 @@ function generic_io_bar(bar)
local f = {}
f.id = -1
f.pre = handle_action
- f.post = io_base_post
+ f.post = io_post
+ f.decode = F_RANGE
f.hide = true
f.name = bar.name
f.size = bar.size
More information about the SerialICE
mailing list