[lustre-devel] [PATCH 103/151] lustre: address issues raised by gcc7
James Simmons
jsimmons at infradead.org
Mon Sep 30 11:56:02 PDT 2019
Starting with gcc version 7 several platforms have enabled new
flags to report potential problems when compling code. For lustre
much of the reported problems deal with potential buffer overruns.
Address these issues in struct lustre_sb_info and provide info
about the fields.
WC-bug-id: https://jira.whamcloud.com/browse/LU-9934
Linux-commit: 61743b8867268 ("LU-9934 build: address issues raised by gcc7")
Signed-off-by: James Simmons <uja.ornl at yahoo.com>
Reviewed-on: https://review.whamcloud.com/30376
Reviewed-by: John L. Hammond <jhammond at whamcloud.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin at intel.com>
Reviewed-by: Oleg Drokin <green at whamcloud.com>
Signed-off-by: James Simmons <jsimmons at infradead.org>
---
fs/lustre/include/lustre_disk.h | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/fs/lustre/include/lustre_disk.h b/fs/lustre/include/lustre_disk.h
index 8b4a243..92618e8 100644
--- a/fs/lustre/include/lustre_disk.h
+++ b/fs/lustre/include/lustre_disk.h
@@ -125,8 +125,10 @@ struct lustre_sb_info {
atomic_t lsi_mounts; /* references to the srv_mnt */
struct kobject *lsi_kobj;
char lsi_svname[MTI_NAME_MAXLEN];
- char lsi_osd_obdname[64];
- char lsi_osd_uuid[64];
+ /* lsi_osd_obdname format = 'lsi->ls_svname'-osd */
+ char lsi_osd_obdname[MTI_NAME_MAXLEN + 4];
+ /* lsi_osd_uuid format = 'lsi->ls_osd_obdname'_UUID */
+ char lsi_osd_uuid[MTI_NAME_MAXLEN + 9];
struct obd_export *lsi_osd_exp;
char lsi_osd_type[16];
char lsi_fstype[16];
--
1.8.3.1
More information about the lustre-devel
mailing list