Patrick Williams | de0582f | 2022-04-08 10:23:27 -0500 | [diff] [blame] | 1 | From 5f6ed003f10ee0bd4a508d5f59129a29f0920dfc Mon Sep 17 00:00:00 2001 |
| 2 | From: Saul Wold <saul.wold@windriver.com> |
| 3 | Date: Thu, 31 Mar 2022 11:21:45 -0700 |
| 4 | Subject: [PATCH] depmod: Ignore .debug directories |
| 5 | |
| 6 | The .debug/<module>.ko files do not have the correct symbol information |
| 7 | since it's split away from the actual <module>.ko file. Just ignore it. |
| 8 | |
| 9 | Upstream-Status: Pending |
| 10 | |
| 11 | Signed-off-by: Saul Wold <saul.wold@windriver.com> |
| 12 | --- |
| 13 | modutils/depmod.c | 3 +++ |
| 14 | 1 file changed, 3 insertions(+) |
| 15 | |
| 16 | diff --git a/modutils/depmod.c b/modutils/depmod.c |
| 17 | index bb42bbe..aa5a2de 100644 |
| 18 | --- a/modutils/depmod.c |
| 19 | +++ b/modutils/depmod.c |
| 20 | @@ -43,6 +43,9 @@ static int FAST_FUNC parse_module(struct recursive_state *state, |
| 21 | /* Arbitrary. Was sb->st_size, but that breaks .gz etc */ |
| 22 | size_t len = (64*1024*1024 - 4096); |
| 23 | |
Andrew Geissler | 6aa7eec | 2023-03-03 12:41:14 -0600 | [diff] [blame^] | 24 | + if (strstr(fname, ".debug") != NULL) |
Patrick Williams | de0582f | 2022-04-08 10:23:27 -0500 | [diff] [blame] | 25 | + return TRUE; |
| 26 | + |
| 27 | if (strrstr(fname, ".ko") == NULL) |
| 28 | return TRUE; |
| 29 | |
| 30 | -- |
| 31 | 2.31.1 |
| 32 | |