summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJosh Stone <jistone@redhat.com>2009-08-10 15:17:35 -0700
committerJosh Stone <jistone@redhat.com>2009-08-10 15:17:35 -0700
commitaeb2727bd6742d8e4ff98882e57078f72da21b68 (patch)
tree1d8e64e172682055a3c0b8068f8dcf93dcc71042
parent7f17af5c9ace193eef48246bcadf42ae9650de67 (diff)
parenta09930468b2d2bae134067d50a9b15b5ba2af548 (diff)
downloadsystemtap-steved-aeb2727bd6742d8e4ff98882e57078f72da21b68.tar.gz
systemtap-steved-aeb2727bd6742d8e4ff98882e57078f72da21b68.tar.xz
systemtap-steved-aeb2727bd6742d8e4ff98882e57078f72da21b68.zip
Merge branch 'master' of ssh://sourceware.org/git/systemtap
-rw-r--r--elaborate.cxx2
-rw-r--r--includes/sys/sdt.h2
-rw-r--r--runtime/staprun/modverify.c5
-rw-r--r--runtime/staprun/staprun.c9
4 files changed, 14 insertions, 4 deletions
diff --git a/elaborate.cxx b/elaborate.cxx
index 93500239..1d7f7930 100644
--- a/elaborate.cxx
+++ b/elaborate.cxx
@@ -1455,7 +1455,7 @@ semantic_pass (systemtap_session& s)
if (rc == 0) rc = semantic_pass_vars (s);
if (rc == 0) rc = semantic_pass_stats (s);
- if (s.probes.size() == 0 && !s.listing_mode)
+ if (s.num_errors() == 0 && s.probes.size() == 0 && !s.listing_mode)
throw semantic_error ("no probes found");
}
catch (const semantic_error& e)
diff --git a/includes/sys/sdt.h b/includes/sys/sdt.h
index f179c2a7..e3a605c5 100644
--- a/includes/sys/sdt.h
+++ b/includes/sys/sdt.h
@@ -68,7 +68,7 @@
#define STAP_UNINLINE_LABEL(label) \
__extension__ static volatile long labelval __attribute__ ((unused)) = (long) &&label
-#if defined __x86_64__ || defined __i386__ || defined __powerpc__
+#if defined __x86_64__ || defined __i386__ || defined __powerpc__ || defined __arm__
#define STAP_NOP "\tnop "
#else
#define STAP_NOP "\tnop 0 "
diff --git a/runtime/staprun/modverify.c b/runtime/staprun/modverify.c
index 15447279..6dc192b2 100644
--- a/runtime/staprun/modverify.c
+++ b/runtime/staprun/modverify.c
@@ -33,6 +33,7 @@
#include "modverify.h"
#include <sys/stat.h>
+#include <errno.h>
/* Function: int check_cert_db_permissions (const char *cert_db_path);
*
@@ -125,6 +126,10 @@ check_cert_db_permissions (const char *cert_db_path) {
rc = stat (cert_db_path, & info);
if (rc)
{
+ /* It is ok if the directory does not exist. This simply means that no signing
+ certificates have been authorized yet. */
+ if (errno == ENOENT)
+ return 0;
fprintf (stderr, "Could not obtain information on certificate database directory %s.\n",
cert_db_path);
perror ("");
diff --git a/runtime/staprun/staprun.c b/runtime/staprun/staprun.c
index c64bf5b3..7eb7f28f 100644
--- a/runtime/staprun/staprun.c
+++ b/runtime/staprun/staprun.c
@@ -132,9 +132,14 @@ static int enable_uprobes(void)
snprintf (runtimeko, sizeof(runtimeko), "%s/uprobes/uprobes.ko",
(getenv("SYSTEMTAP_RUNTIME") ?: PKGDATADIR "/runtime"));
dbug(2, "Inserting uprobes module from SystemTap runtime %s.\n", runtimeko);
- argv[0] = NULL;
+ i = 0;
+ argv[i++] = "/sbin/insmod";
+ argv[i++] = runtimeko;
+ argv[i] = NULL;
+ if (run_as(0, 0, 0, argv[0], argv) == 0)
+ return 0;
- return insert_module(runtimeko, NULL, argv);
+ return 1; /* failure */
}
static int insert_stap_module(void)