X-Git-Url: http://git.lttng.org./?a=blobdiff_plain;f=ltt%2Fbranches%2Fpoly%2Fltt%2Ffacility.c;h=380689b4628e773ea4195c8d2fe122e811702cb8;hb=880fded3c234f271a7437bf055fbefb6aaca2386;hp=8cb8cff44e3c7f1f4b061a4eb5bd17640a4d5b7e;hpb=dd3a6d3981f13150b4262a418f5ee00c715eda71;p=lttv.git diff --git a/ltt/branches/poly/ltt/facility.c b/ltt/branches/poly/ltt/facility.c index 8cb8cff4..380689b4 100644 --- a/ltt/branches/poly/ltt/facility.c +++ b/ltt/branches/poly/ltt/facility.c @@ -138,10 +138,13 @@ int ltt_facility_open(LttFacility *f, LttTrace * t, gchar * pathname) checkNamedTypesImplemented(&fac->named_types); generateChecksum(fac->name, &checksum, &fac->events); - if(checksum == f->checksum) { + // FIXME if(checksum == f->checksum) { generateFacility(f, fac, checksum); generated = TRUE; - } + //} + if (checksum != f->checksum) + g_warning("Facility checksum mismatch for facility %s : kernel 0x%X vs " + "XML 0x%X\n", fac->name, f->checksum, checksum); g_free(fac->name); free(fac->capname); @@ -194,7 +197,7 @@ void generateFacility(LttFacility *f, facility_t *fac, guint32 checksum) table_t *named_types = &fac->named_types; g_assert(f->name == g_quark_from_string(facilityName)); - g_assert(f->checksum == checksum); + //g_assert(f->checksum == checksum); //f->event_number = events->position; @@ -392,10 +395,14 @@ void construct_fields(LttFacility *fac, { guint i; type->enum_map = g_hash_table_new(g_direct_hash, g_direct_equal); + type->lowest_value = G_MAXINT32; + type->highest_value = G_MININT32; for(i=0; ilabels.position; i++) { GQuark value = g_quark_from_string((char*)td->labels.array[i]); gint key = *(int*)td->labels_values.array[i]; g_hash_table_insert(type->enum_map, (gpointer)key, (gpointer)value); + type->highest_value = max(key, type->highest_value); + type->lowest_value = min(key, type->lowest_value); } } g_assert(type->size != 0);