From: Richard Weinberger <richard@xxxxxx> ...such that we can implement NOP variants of some functions. This will help to reduce fastmap specific ifdefs in other c files. Signed-off-by: Richard Weinberger <richard@xxxxxx> Reviewed-by: Tanya Brokhman <tlinder@xxxxxxxxxxxxxx> Conflicts: drivers/mtd/ubi/ubi.h Fixed minor conflict. Signed-off-by: Teresa Remmet <t.remmet@xxxxxxxxx> --- drivers/mtd/ubi/ubi.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/mtd/ubi/ubi.h b/drivers/mtd/ubi/ubi.h index 5bceb53..2ed28f7 100644 --- a/drivers/mtd/ubi/ubi.h +++ b/drivers/mtd/ubi/ubi.h @@ -837,11 +837,16 @@ int ubi_compare_lebs(struct ubi_device *ubi, const struct ubi_ainf_peb *aeb, int pnum, const struct ubi_vid_hdr *vid_hdr); /* fastmap.c */ +#ifdef CONFIG_MTD_UBI_FASTMAP size_t ubi_calc_fm_size(struct ubi_device *ubi); int ubi_update_fastmap(struct ubi_device *ubi); int ubi_scan_fastmap(struct ubi_device *ubi, struct ubi_attach_info *ai, int fm_anchor); void ubi_free_fastmap(struct ubi_device *ubi); +#else +static inline int ubi_update_fastmap(struct ubi_device *ubi) { return 0; } +#endif + /* * ubi_rb_for_each_entry - walk an RB-tree. * @rb: a pointer to type 'struct rb_node' to use as a loop counter -- 1.9.1 _______________________________________________ barebox mailing list barebox@xxxxxxxxxxxxxxxxxxx http://lists.infradead.org/mailman/listinfo/barebox