History log of /openbmc/hiomapd/vpnor/ (Results 26 – 50 of 63)
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
0297e5b814-Mar-2019 Andrew Jeffery <andrew@aj.id.au>

mboxd: Remove flash API compatibility shim

The flash API compatibility was kept to reduce the line noise in the
previous backend patch. Remove the compatibility layer now and convert
the remaining c

mboxd: Remove flash API compatibility shim

The flash API compatibility was kept to reduce the line noise in the
previous backend patch. Remove the compatibility layer now and convert
the remaining call-sites.

Change-Id: I4b6e54f4463059a7804918add81e7572db7b7c21
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

show more ...

f1e547c713-Mar-2019 Evan Lojewski <github@meklort.com>

mboxd: Add a backend abstraction layer to mboxd.

Introduce a backend abstraction, enabling multiple implementations to be
compiled in at once. This change formally abstracts the two existing
backend

mboxd: Add a backend abstraction layer to mboxd.

Introduce a backend abstraction, enabling multiple implementations to be
compiled in at once. This change formally abstracts the two existing
backends, mtd and vpnor.

With the backend abstraction in place, subsequent backends are easier to
implement.

This change is based of Evan's work and he retains authorship credit. I
(AJ) have reworked the patch to pass the vpnor tests, refactored some
parts to enable broader use of const structures and others to clarify
the initialisation sequences.

Due to the existing lack of abstraction the patch has unfortunately
wide-ranging impacts. I've whittled it down as much as I consider
reasonable.

Change-Id: I29984a36dae4ea86ec00b853d2a756f0b9afb3ec
Signed-off-by: Evan Lojewski <github@meklort.com>
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

show more ...


/openbmc/hiomapd/Makefile.am
/openbmc/hiomapd/backend.h
/openbmc/hiomapd/control.c
/openbmc/hiomapd/lpc.c
/openbmc/hiomapd/lpc.h
/openbmc/hiomapd/mboxd.c
/openbmc/hiomapd/mboxd.h
/openbmc/hiomapd/mtd/Makefile.am.include
/openbmc/hiomapd/mtd/backend.c
/openbmc/hiomapd/mtd/backend.h
/openbmc/hiomapd/protocol.c
/openbmc/hiomapd/test/Makefile.am.include
/openbmc/hiomapd/test/backend.c
/openbmc/hiomapd/test/flash_copy.c
/openbmc/hiomapd/test/flash_erase.c
/openbmc/hiomapd/test/flash_write.c
/openbmc/hiomapd/test/implicit_flush.c
/openbmc/hiomapd/test/mark_write_erased_v2.c
/openbmc/hiomapd/test/mbox.c
/openbmc/hiomapd/test/mbox.h
/openbmc/hiomapd/test/write_flush_v2.c
/openbmc/hiomapd/test/write_window_dirty_erase.c
/openbmc/hiomapd/transport_mbox.c
Makefile.am.include
backend.cpp
mboxd_pnor_partition_table.cpp
mboxd_pnor_partition_table.h
pnor_partition.cpp
pnor_partition.hpp
pnor_partition_table.cpp
pnor_partition_table.hpp
test/Makefile.am.include
test/create_pnor_partition_table.cpp
test/create_read_window_oob.cpp
test/create_read_window_partition_exists.cpp
test/create_read_window_partition_invalid.cpp
test/create_read_window_remap.cpp
test/create_read_window_size.cpp
test/create_read_window_straddle_partitions.cpp
test/create_read_window_toc.cpp
test/create_write_window_ro_partition.cpp
test/create_write_window_rw_partition.cpp
test/create_write_window_unmapped.cpp
test/dump_flash.cpp
test/force_readonly_toc.cpp
test/read_patch.cpp
test/tmpd.hpp
test/toc_lookup_failed.cpp
test/toc_lookup_found.cpp
test/toc_missing_file.cpp
test/toc_overlap.cpp
test/write_patch.cpp
test/write_patch_resize.cpp
test/write_prsv.cpp
test/write_ro.cpp
test/write_rw.cpp
test/write_toc.cpp
/openbmc/hiomapd/windows.c
cb93504e14-Mar-2019 Andrew Jeffery <andrew@aj.id.au>

flash: Introduce flash_validate()

Clean up the protocol_negotiate_version() mess. The existing approach
came about due to viewing the vpnor implementation as an edge case in
its own right. The code

flash: Introduce flash_validate()

Clean up the protocol_negotiate_version() mess. The existing approach
came about due to viewing the vpnor implementation as an edge case in
its own right. The code becomes much neater if we consider all backends
as equal and afford them the callbacks necessary for correct behaviour.

Change-Id: Ifaeee9da459818cf22b2f137ddc5b8d0356b9be9
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

show more ...

4e75a27a14-Mar-2019 Andrew Jeffery <andrew@aj.id.au>

vpnor: Test if HBB placement exceeds reserved memory bounds

If a host firmware image is provided where the placement of HBB exceeds
the reserved memory size then an out-of-bounds write would occur.

vpnor: Test if HBB placement exceeds reserved memory bounds

If a host firmware image is provided where the placement of HBB exceeds
the reserved memory size then an out-of-bounds write would occur.

Change-Id: I0a98cb7417511cc8dd5bd2e12c9232ebc912dcd6
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

show more ...

261f61a113-Mar-2019 Andrew Jeffery <andrew@aj.id.au>

vpnor: Shuffle and rework includes for sanity

Include ordering and whether or not C linkage is forced by `extern "C"`
blocks can cause headaches at link time. Ensure that all C dependencies
are incl

vpnor: Shuffle and rework includes for sanity

Include ordering and whether or not C linkage is forced by `extern "C"`
blocks can cause headaches at link time. Ensure that all C dependencies
are included in an `extern C` block before other includes occur. Also
include the C++ versions of string.h and assert.h

Change-Id: Ia96f6044d40c8eccb907b65924efcf62ac7a89c3
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

show more ...

7a85d22a13-Nov-2018 Andrew Jeffery <andrew@aj.id.au>

vpnor: Enforce a read-only FFS ToC regardless of flags

The virtual PNOR implementation never properly honoured writes to the
FFS ToC, as the ToC's binary representation is generated from the CSV
fil

vpnor: Enforce a read-only FFS ToC regardless of flags

The virtual PNOR implementation never properly honoured writes to the
FFS ToC, as the ToC's binary representation is generated from the CSV
file shipped in the PNOR squashfs image.

What *did* happen was that opening a write window to the ToC region
succeeded and writes could be flushed, but the flushed writes were never
read, and ToC representation internal to mboxd was never updated to
match the written state. Thus the written values "persisted" until the
ToC's window fell out of the cache (with 64MiB reserved regions,
probably on a host reboot).

Short circuit the insanity of handling FFS more than we have to by
forcefully marking the ToC as read-only, regardless of the flag
configuration shipped in the CSV representation. This prevents the host
from successfully opening a write window and thus the host can have no
expectation of write persistence.

Change-Id: Ib2788c56b245da506cb7d607c0758b17785766cf
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

show more ...

8a0efd5e13-Nov-2018 Andrew Jeffery <andrew@aj.id.au>

vpnor: test: Add force_readonly_toc

This ensures that the ToC presented to the host indicates that it is not
writable. The virtual PNOR implementation has never properly honoured
writes to the ToC,

vpnor: test: Add force_readonly_toc

This ensures that the ToC presented to the host indicates that it is not
writable. The virtual PNOR implementation has never properly honoured
writes to the ToC, so lets at least tell the host.

As the code has not yet been fixed to implement the desired behaviour,
add the test to XFAIL_TESTS.

Change-Id: Ia13a0f907f916d6dec3979b17685d54bc578a106
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

show more ...

8998575412-Nov-2018 Andrew Jeffery <andrew@aj.id.au>

vpnor: Add write-to-writable-ToC test

Tests if mutations survive re-opening the window. They don't, so add the
test to XFAIL_TESTS.

Change-Id: Ic2f844c30a7da35033bf03012ea452718d2843e4
Signed-off-b

vpnor: Add write-to-writable-ToC test

Tests if mutations survive re-opening the window. They don't, so add the
test to XFAIL_TESTS.

Change-Id: Ic2f844c30a7da35033bf03012ea452718d2843e4
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

show more ...

d5f1d40f11-Oct-2018 William A. Kennington III <wak@google.com>

clang-format: Pull the format rules from the openbmc/docs repo

This makes it consistent with other openbmc projects for c++ formatting.

Tested:
Run through the unit test suite.

Change-Id: I920

clang-format: Pull the format rules from the openbmc/docs repo

This makes it consistent with other openbmc projects for c++ formatting.

Tested:
Run through the unit test suite.

Change-Id: I92030ce5b42de01360393687fb438faf26f36ac8
Signed-off-by: William A. Kennington III <wak@google.com>

show more ...

cc65061829-Aug-2018 Andrew Jeffery <andrew@aj.id.au>

vpnor: pnor_partition: Debugging for Request.fulfil()

Change-Id: If74d8d1983c2b32b3ed6264bbdb7f49118d5a1f2
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

26558dbb09-Aug-2018 Andrew Jeffery <andrew@aj.id.au>

mboxd: Refactor and rename mbox.h to mboxd.h

Refine the purpose of the header file to represent what's required for
the daemon itself, not its constituent pieces. Rather, split those
definitions out

mboxd: Refactor and rename mbox.h to mboxd.h

Refine the purpose of the header file to represent what's required for
the daemon itself, not its constituent pieces. Rather, split those
definitions out to their respective header files and include them as
necessary.

Finally the header file is renamed to better reflect its purpose.

Change-Id: I48c409f57d96c844589cd865b24f197477dfe87c
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

show more ...


/openbmc/hiomapd/control.c
/openbmc/hiomapd/control_dbus.c
/openbmc/hiomapd/control_dbus.h
/openbmc/hiomapd/control_legacy.c
/openbmc/hiomapd/flash.c
/openbmc/hiomapd/flash.h
/openbmc/hiomapd/lpc.c
/openbmc/hiomapd/lpc.h
/openbmc/hiomapd/lpc_reset.c
/openbmc/hiomapd/mboxd.c
/openbmc/hiomapd/mboxd.h
/openbmc/hiomapd/protocol.c
/openbmc/hiomapd/protocol.h
/openbmc/hiomapd/protocol_negotiate_version.c
/openbmc/hiomapd/test/bmc_event_ack_v2.c
/openbmc/hiomapd/test/close_window_v2.c
/openbmc/hiomapd/test/create_oversize_window.c
/openbmc/hiomapd/test/create_read_window_v2.c
/openbmc/hiomapd/test/create_write_window_v2.c
/openbmc/hiomapd/test/create_zero_size_window.c
/openbmc/hiomapd/test/flash_copy.c
/openbmc/hiomapd/test/flash_erase.c
/openbmc/hiomapd/test/flash_write.c
/openbmc/hiomapd/test/get_flash_info_v2.c
/openbmc/hiomapd/test/get_mbox_info_v2.c
/openbmc/hiomapd/test/get_mbox_info_v2_timeout.c
/openbmc/hiomapd/test/implicit_flush.c
/openbmc/hiomapd/test/invalid_command.c
/openbmc/hiomapd/test/mark_read_dirty.c
/openbmc/hiomapd/test/mark_write_dirty_v2.c
/openbmc/hiomapd/test/mark_write_erased_v2.c
/openbmc/hiomapd/test/mbox.c
/openbmc/hiomapd/test/mbox.h
/openbmc/hiomapd/test/read_window_cycle.c
/openbmc/hiomapd/test/read_window_mark_write_erased.c
/openbmc/hiomapd/test/read_window_write_flush.c
/openbmc/hiomapd/test/request_high_version.c
/openbmc/hiomapd/test/request_low_version.c
/openbmc/hiomapd/test/reset_state.c
/openbmc/hiomapd/test/sequence_numbers.c
/openbmc/hiomapd/test/write_flush_v2.c
/openbmc/hiomapd/test/write_window_dirty_erase.c
/openbmc/hiomapd/transport.h
/openbmc/hiomapd/transport_mbox.c
/openbmc/hiomapd/transport_mbox.h
lpc_reset.cpp
mboxd_pnor_partition_table.cpp
pnor_partition.hpp
pnor_partition_table.cpp
pnor_partition_table.hpp
protocol.cpp
protocol_negotiate_version.cpp
test/tmpd.hpp
test/write_patch.cpp
test/write_patch_resize.cpp
test/write_prsv.cpp
test/write_ro.cpp
test/write_rw.cpp
/openbmc/hiomapd/windows.c
/openbmc/hiomapd/windows.h
8eab215109-Aug-2018 Andrew Jeffery <andrew@aj.id.au>

mboxd: Cleanup errnos not captured by tests

Change-Id: I95d1eee536e4113867fceb5dcda45e15dc032002
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

c7d1947e07-Aug-2018 Andrew Jeffery <andrew@aj.id.au>

vpnor: Hijack protocol rather than transport

By hijacking the transport the changes in behaviour were limited to the
mailbox interface. Now that we have a DBus interface as well this would
lead to i

vpnor: Hijack protocol rather than transport

By hijacking the transport the changes in behaviour were limited to the
mailbox interface. Now that we have a DBus interface as well this would
lead to inconsistent behaviour dependent on the transport.

Instead of hooking the transport, push the hook down to the protocol
level where we will achieve consistent behaviour across all transports.

Change-Id: I437866a6dbda107149336c15a00ee1aa058f5875
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

show more ...

1e531afd06-Aug-2018 Andrew Jeffery <andrew@aj.id.au>

protocol: Add get_info

Change-Id: Ie3338714813bb65f5d37fcd046dd5bebc0ba21f0
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

457a6e5f07-Aug-2018 Andrew Jeffery <andrew@aj.id.au>

mboxd: Rename mboxd_msg to transport_mbox

Change-Id: I0f4e206648c02a98fa938a7e582470c8d90904f1
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

f593b1bd07-Aug-2018 Andrew Jeffery <andrew@aj.id.au>

mboxd: Rename windows files

Change-Id: I44e110906fd0f751f8f34b175f971e65896a7301
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

17971e4408-Aug-2018 Andrew Jeffery <andrew@aj.id.au>

lpc: Rename reset_lpc to lpc_reset

Change-Id: Iee234830b7ea93a7c51b45217d87162e14ef56ee
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

17079d1d08-Aug-2018 Andrew Jeffery <andrew@aj.id.au>

lpc: Rename point_to_memory to lpc_map_memory

Change-Id: Iee32689e1c222a422aadf217d1fb0c817250de6b
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

856c717608-Aug-2018 Andrew Jeffery <andrew@aj.id.au>

lpc: Drop __cplusplus guard

C++ concepts should go in C++ files.

Change-Id: I7a0979dda90b7968000e05fdf7029dea748a33cc
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

cd18611e07-Aug-2018 Andrew Jeffery <andrew@aj.id.au>

mboxd: Rename lpc source files

Change-Id: I289618c90b2df8911e362397b7eab99403c86c05
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

0293f2f508-Aug-2018 Andrew Jeffery <andrew@aj.id.au>

flash: Rename write_flash to flash_write

Change-Id: I4b41aac597299c93369d8998b03a7d3e2a128742
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

4f5d29cf08-Aug-2018 Andrew Jeffery <andrew@aj.id.au>

flash: Rename erase_flash to flash_erase

Change-Id: I417319aadb2fdbfa2d688bb26b5515d2f9265994
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

f953f79808-Aug-2018 Andrew Jeffery <andrew@aj.id.au>

flash: Rename set_flash_bytemap to flash_set_bytemap

Change-Id: I0bd244ab1f8f37cdf54a5dc9198651ade7ed0876
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

e0cdd3ea08-Aug-2018 Andrew Jeffery <andrew@aj.id.au>

flash: Rename copy_flash to flash_copy

Change-Id: If449889fca3370e25a65719d2f5c5ec90258d633
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

dec6ca6108-Aug-2018 Andrew Jeffery <andrew@aj.id.au>

flash: Rename free_flash_dev to flash_dev_free

Change-Id: I3d3da6312217b6b869fa3f62a1d4752be98fd609
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

123