commonlib/bsd: Remove cb_err_t
cb_err_t was meant to be used in place of `enum cb_err` in all situations, but the choice to use a typedef here seems to be controversial. We should not be arbitrarily using two different identifiers for the same thing across the codebase, so since there are no use cases for serializing enum cb_err at the moment (which would be the primary reason to typedef a fixed-width integer instead), remove cb_err_t again for now. Signed-off-by: Julius Werner <jwerner@chromium.org> Change-Id: Iaec36210d129db26d51f0a105d3de070c03b686b Reviewed-on: https://review.coreboot.org/c/coreboot/+/62600 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Yu-Ping Wu <yupingso@google.com> Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
This commit is contained in:
@ -80,15 +80,15 @@ vb2_error_t vb2_digest_finalize(struct vb2_digest_context *dc, uint8_t *digest,
|
||||
}
|
||||
|
||||
/* Original function alias created by test framework. Used for call wrapping in mock below. */
|
||||
cb_err_t __real_cbfs_lookup(cbfs_dev_t dev, const char *name, union cbfs_mdata *mdata_out,
|
||||
size_t *data_offset_out, struct vb2_hash *metadata_hash);
|
||||
enum cb_err __real_cbfs_lookup(cbfs_dev_t dev, const char *name, union cbfs_mdata *mdata_out,
|
||||
size_t *data_offset_out, struct vb2_hash *metadata_hash);
|
||||
|
||||
cb_err_t cbfs_lookup(cbfs_dev_t dev, const char *name, union cbfs_mdata *mdata_out,
|
||||
size_t *data_offset_out, struct vb2_hash *metadata_hash)
|
||||
enum cb_err cbfs_lookup(cbfs_dev_t dev, const char *name, union cbfs_mdata *mdata_out,
|
||||
size_t *data_offset_out, struct vb2_hash *metadata_hash)
|
||||
{
|
||||
const cb_err_t err =
|
||||
const enum cb_err err =
|
||||
__real_cbfs_lookup(dev, name, mdata_out, data_offset_out, metadata_hash);
|
||||
assert_int_equal(mock_type(cb_err_t), err);
|
||||
assert_int_equal(mock_type(enum cb_err), err);
|
||||
return err;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user