1
0
mirror of https://xff.cz/git/u-boot/ synced 2026-01-27 12:49:21 +01:00
Files
u-boot-megous/include
Simon Glass a51eb8de31 blk: Use a function for whether block devices are available
At present we use HAVE_BLOCK_DEVICE to indicate when block devices are
available.

This is a very strange option, since it partially duplicates the BLK
option used by driver model. It also covers both U-Boot proper and SPL,
even though one might have block devices and another not.

As a first step towards correcting this, create a new inline function
called blk_enabled() which indicates if block devices are available.
This cannot be used in Makefiles, or #if clauses, but can be used in C
code.

A function is useful because we cannot use CONFIG_IS_ENABLED(BLK) to
decide if block devices are needed, since we must consider the legacy
block interface, enabled by HAVE_BLOCK_DEVICE

Update a few places where it can be used and drop some unnecessary #if
checks around some functions in disk/part.c - rely on the compiler's
dead-code elimination instead.

Signed-off-by: Simon Glass <sjg@chromium.org>
2022-09-16 11:05:00 -04:00
..
2022-07-05 14:37:16 +02:00
2019-12-06 16:44:20 -05:00
2022-08-04 16:18:47 -04:00
2022-01-19 18:11:34 +01:00
2022-07-11 14:58:57 -04:00
2022-01-19 18:11:34 +01:00
2022-07-07 09:29:08 -04:00
2022-04-11 10:00:30 -04:00
2022-01-19 18:11:34 +01:00
2022-07-26 02:30:56 -06:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2020-05-11 10:16:49 +05:30
2021-01-15 14:36:12 -05:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-30 01:25:00 +00:00
2022-01-30 01:25:00 +00:00
2022-01-30 01:25:00 +00:00
2022-01-30 01:25:00 +00:00
2022-01-30 01:25:00 +00:00
2022-01-30 01:25:00 +00:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-06-28 03:09:51 +01:00
2022-01-19 18:11:34 +01:00
2022-04-25 10:00:04 -04:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-08-12 08:17:11 -04:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-04-06 14:01:42 -04:00
2022-05-28 10:59:27 +02:00
2022-01-19 18:11:34 +01:00
2022-03-30 13:02:55 -04:00
2022-03-30 13:02:55 -04:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2021-01-30 14:25:42 -07:00
2022-01-19 18:11:34 +01:00
2020-02-05 19:33:46 -07:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2020-08-03 22:19:54 -04:00
2022-02-03 12:16:01 -05:00
2022-01-15 10:57:22 +01:00
2022-01-19 18:11:34 +01:00
2022-03-15 16:19:29 -04:00
2022-04-06 14:01:42 -04:00
2022-01-19 18:11:34 +01:00
2022-08-04 16:18:47 -04:00
2021-07-07 19:52:22 -04:00
2022-07-26 11:29:00 +02:00
2021-04-10 08:04:42 -04:00
2020-10-30 10:56:11 -04:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-06-08 13:59:53 -04:00
2022-01-19 18:11:34 +01:00
2021-08-30 14:13:28 -04:00
2022-06-28 17:03:32 -04:00
2022-07-26 11:29:02 +02:00
2022-01-19 18:11:34 +01:00
2021-10-31 08:46:44 -04:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2019-11-07 18:39:16 -05:00
2022-01-19 18:11:34 +01:00
2022-07-07 09:29:08 -04:00
2022-04-28 09:26:44 -04:00
2020-04-17 12:32:36 -04:00
2022-08-10 13:38:30 -04:00
2022-08-20 18:07:32 -06:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-24 10:35:10 -05:00
2021-09-28 12:03:20 -04:00
2022-08-08 10:50:20 -04:00
2022-01-19 18:11:34 +01:00
2022-06-08 14:00:22 -04:00
2022-06-28 03:09:51 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2021-07-07 19:52:24 -04:00
2022-01-19 18:11:34 +01:00
2021-04-12 17:44:55 -04:00
2022-01-19 18:11:34 +01:00
2020-06-14 21:07:20 +02:00
2022-07-08 12:20:28 -04:00
2022-01-19 18:11:34 +01:00
2020-02-05 19:33:46 -07:00
2022-01-19 18:11:34 +01:00
2020-06-14 21:07:20 +02:00
2022-02-09 09:16:48 -05:00
2022-01-19 18:11:34 +01:00
2022-04-01 15:03:13 -04:00
2022-04-01 16:56:54 -04:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-09-13 12:08:40 -04:00
2022-01-19 18:11:34 +01:00
2022-04-06 14:03:17 -04:00
2022-01-26 23:23:17 +01:00
2022-01-19 18:11:34 +01:00
2020-08-03 22:19:54 -04:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2021-01-27 17:03:16 -05:00
2022-08-12 08:17:11 -04:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-03-28 20:17:20 +02:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2022-01-19 18:11:34 +01:00
2021-01-15 14:36:12 -05:00