Browse code

core: exposed module version control function

Daniel-Constantin Mierla authored on 16/02/2021 15:22:45
Showing 2 changed files
... ...
@@ -335,7 +335,10 @@ error:
335 335
 	return ret;
336 336
 }
337 337
 
338
-static inline int version_control(void *handle, char *path)
338
+/**
339
+ * check the version of loaded module
340
+ */
341
+int ksr_version_control(void *handle, char *path)
339 342
 {
340 343
 	char **m_ver;
341 344
 	char **m_flags;
... ...
@@ -572,7 +575,7 @@ reload:
572 575
 		}
573 576
 	}
574 577
 	/* version control */
575
-	if (!version_control(handle, path)) {
578
+	if (!ksr_version_control(handle, path)) {
576 579
 		ksr_exit(-1);
577 580
 	}
578 581
 	/* launch register */
... ...
@@ -551,4 +551,6 @@ int ksr_shutdown_phase(void);
551 551
 
552 552
 int ksr_locate_module(char *mod_path, char **new_path);
553 553
 
554
+int ksr_version_control(void *handle, char *path);
555
+
554 556
 #endif /* sr_module_h */