diff options
Diffstat (limited to 'meta/recipes-core/busybox/busybox/fail_on_no_media.patch')
-rw-r--r-- | meta/recipes-core/busybox/busybox/fail_on_no_media.patch | 28 |
1 files changed, 18 insertions, 10 deletions
diff --git a/meta/recipes-core/busybox/busybox/fail_on_no_media.patch b/meta/recipes-core/busybox/busybox/fail_on_no_media.patch index 820acc2684..38db52538e 100644 --- a/meta/recipes-core/busybox/busybox/fail_on_no_media.patch +++ b/meta/recipes-core/busybox/busybox/fail_on_no_media.patch | |||
@@ -1,3 +1,8 @@ | |||
1 | From a35e79002d36cca3c272ba5625aec86d6b7a38a8 Mon Sep 17 00:00:00 2001 | ||
2 | From: Saul Wold <sgw@linux.intel.com> | ||
3 | Date: Tue, 9 Apr 2013 23:25:54 -0700 | ||
4 | Subject: [PATCH] busybox: fail on no media | ||
5 | |||
1 | Upstream-Status: Denied | 6 | Upstream-Status: Denied |
2 | [https://www.mail-archive.com/busybox@busybox.net/msg22354.html] | 7 | [https://www.mail-archive.com/busybox@busybox.net/msg22354.html] |
3 | 8 | ||
@@ -10,16 +15,18 @@ removed, but that would be harder to accomplish. | |||
10 | 15 | ||
11 | Signed-off-by: Saul Wold <sgw@linux.intel.com> | 16 | Signed-off-by: Saul Wold <sgw@linux.intel.com> |
12 | 17 | ||
18 | --- | ||
19 | util-linux/mount.c | 8 ++++++++ | ||
20 | 1 file changed, 8 insertions(+) | ||
13 | 21 | ||
14 | Index: busybox-1.20.2/util-linux/mount.c | 22 | diff --git a/util-linux/mount.c b/util-linux/mount.c |
15 | =================================================================== | 23 | index 4e65b6b..9d7a566 100644 |
16 | --- busybox-1.20.2.orig/util-linux/mount.c | 24 | --- a/util-linux/mount.c |
17 | +++ busybox-1.20.2/util-linux/mount.c | 25 | +++ b/util-linux/mount.c |
18 | @@ -598,7 +598,13 @@ static int mount_it_now(struct mntent *m | 26 | @@ -746,6 +746,14 @@ static int mount_it_now(struct mntent *mp, unsigned long vfsflags, char *filtero |
19 | break; | ||
20 | errno = errno_save; | 27 | errno = errno_save; |
21 | } | 28 | } |
22 | - | 29 | |
23 | + /* | 30 | + /* |
24 | + * Break if there is no media, no point retrying for all | 31 | + * Break if there is no media, no point retrying for all |
25 | + * fs types since there is no media available | 32 | + * fs types since there is no media available |
@@ -27,6 +34,7 @@ Index: busybox-1.20.2/util-linux/mount.c | |||
27 | + if (rc == -1 && errno == ENOMEDIUM) { | 34 | + if (rc == -1 && errno == ENOMEDIUM) { |
28 | + bb_perror_msg_and_die("mounting %s on %s failed", mp->mnt_fsname, mp->mnt_dir); | 35 | + bb_perror_msg_and_die("mounting %s on %s failed", mp->mnt_fsname, mp->mnt_dir); |
29 | + } | 36 | + } |
30 | if (!rc || (vfsflags & MS_RDONLY) || (errno != EACCES && errno != EROFS)) | 37 | + |
31 | break; | 38 | // Should we retry read-only mount? |
32 | if (!(vfsflags & MS_SILENT)) | 39 | if (vfsflags & MS_RDONLY) |
40 | break; // no, already was tried | ||