]> Zhao Yanbai Git Server - minix.git/commitdiff
Basic statistical profiling fixes 91/3291/1
authorDavid van Moolenbroek <david@minix3.org>
Thu, 28 Jan 2016 12:09:35 +0000 (13:09 +0100)
committerDavid van Moolenbroek <david@minix3.org>
Thu, 28 Jan 2016 12:09:35 +0000 (13:09 +0100)
At least it works again now.  Sprofalyze should be made aware of the
kernel information page, though (i.e., /proc/ipcvecs).

Change-Id: Id4e5f6417ad152607c4e53b323b6f65ea4b10c6e

minix/commands/sprofalyze/sprofalyze.c
minix/include/minix/syslib.h
minix/kernel/system/do_sprofile.c
minix/lib/libsys/sys_sprof.c

index 5f31e471437637ee4d408a77a95ed1509b5f0cc4..2b99814a307e503691d7f7b9491318e0c4639e17 100755 (executable)
 static const char *default_binaries[] = {
        "kernel/kernel",
        "servers/",
-       "drivers/",
+       /* XXX this should not be necessary */
+       "drivers/audio/",
+       "drivers/bus/",
+       "drivers/clock/",
+       "drivers/eeprom/",
+       "drivers/examples/",
+       "drivers/hid/",
+       "drivers/iommu/",
+       "drivers/net/",
+       "drivers/power/",
+       "drivers/printer/",
+       "drivers/sensors/",
+       "drivers/storage/",
+       "drivers/system/",
+       "drivers/tty/",
+       "drivers/usb/",
+       "drivers/video/",
+       "drivers/vmm_guest/",
+       "fs/",
+       "net/",
 };
 
-static const char *src_path = "/usr/src";
+static const char *src_path = "/usr/src/minix";
 
 /* types */
 
index 45b92364967d5d8348c173d49dc5cb216d4e270b..6f884508d59465fe77720a7b4b3df7e67553df06 100644 (file)
@@ -253,7 +253,7 @@ int pci_get_bar(int devind, int port, u32_t *base, u32_t *size, int
 
 /* Profiling. */
 int sys_sprof(int action, int size, int freq, int type, endpoint_t
-       endpt, void *ctl_ptr, void *mem_ptr);
+       endpt, vir_bytes ctl_ptr, vir_bytes mem_ptr);
 
 /* machine context */
 int sys_getmcontext(endpoint_t proc, vir_bytes mcp);
index 581e350751ba7b866851a65908c0a16bf249df98..d84e22c95f160a14aaa16715c692d36abdd75ecc 100644 (file)
@@ -77,7 +77,7 @@ int do_sprofile(struct proc * caller, message * m_ptr)
                        break;
                case PROF_NMI:
                        err = nmi_watchdog_start_profiling(
-                               _ptr->m_lsys_krn_sys_sprof.freq);
+                               m_ptr->m_lsys_krn_sys_sprof.freq);
                        if (err)
                                return err;
                        break;
index 5ac3550c8ac300f93562efc89bc4212739101de5..a43b0fbb369ffb6aff95a5902c29f503022ae3f0 100644 (file)
@@ -11,8 +11,8 @@ int size;                             /* available profiling memory */
 int freq;                              /* sample frequency */
 int type;
 endpoint_t endpt;                      /* caller endpoint */
-void *ctl_ptr;                         /* location of info struct */
-void *mem_ptr;                         /* location of profiling memory */
+vir_bytes ctl_ptr;                     /* location of info struct */
+vir_bytes mem_ptr;                     /* location of profiling memory */
 {
   message m;