Ring buffer: use shmp (shared-memory pointers) for per-channel shm structures
[ust.git] / libust / buffers.c
index 8ecebb9355060bb752d7f66f9f0f4f0895ac747f..0e198da1bc21e3a023e63c10156bc38f3c463fd3 100644 (file)
@@ -55,31 +55,6 @@ static CDS_LIST_HEAD(ust_buffers_channels);
 static void ltt_force_switch(struct ust_buffer *buf,
                enum force_switch_mode mode);
 
-static int get_n_cpus(void)
-{
-       int result;
-       static int n_cpus = 0;
-
-       if(!n_cpus) {
-               /* On Linux, when some processors are offline
-                * _SC_NPROCESSORS_CONF counts the offline
-                * processors, whereas _SC_NPROCESSORS_ONLN
-                * does not. If we used _SC_NPROCESSORS_ONLN,
-                * getcpu() could return a value greater than
-                * this sysconf, in which case the arrays
-                * indexed by processor would overflow.
-                */
-               result = sysconf(_SC_NPROCESSORS_CONF);
-               if(result == -1) {
-                       return -1;
-               }
-
-               n_cpus = result;
-       }
-
-       return n_cpus;
-}
-
 /**
  * _ust_buffers_strncpy_fixup - Fix an incomplete string in a ltt_relay buffer.
  * @buf : buffer
This page took 0.022082 seconds and 4 git commands to generate.