From e9e87922de74c338f2254679a96e27778e982f54 Mon Sep 17 00:00:00 2001 From: Boaz Harrosh Date: Fri, 11 Feb 2011 13:47:12 +0200 Subject: [PATCH] osd-target: Print the function name and not the file-name. Change the _sense_build_* macros to output function names and not file-names. Easier to ctags to. Signed-off-by: Boaz Harrosh --- inst.sh | 10 ++++++++++ osd-target/target-sense.h | 8 ++++---- 2 files changed, 14 insertions(+), 4 deletions(-) create mode 100644 inst.sh diff --git a/inst.sh b/inst.sh new file mode 100644 index 0000000..a1c03f4 --- /dev/null +++ b/inst.sh @@ -0,0 +1,10 @@ +#!/bin/bash +# + +dest=root@10.65.163.104:/root/ + +scp tgt/usr/tgtd $dest +scp tgt/usr/tgtadm $dest +scp tgt/usr/tgtimg $dest + +scp /usr/local/lib/libsqlite3.so.8 $dest diff --git a/osd-target/target-sense.h b/osd-target/target-sense.h index 6733c40..92a04c4 100644 --- a/osd-target/target-sense.h +++ b/osd-target/target-sense.h @@ -19,7 +19,7 @@ #define __TARGET_SENSE_H #define sense_header_build(data, len, key, code, additional_len) \ - _sense_header_build(data, len, key, code, additional_len, __FILE__, __LINE__) + _sense_header_build(data, len, key, code, additional_len, __func__, __LINE__) int _sense_header_build(uint8_t *data, int len, uint8_t key, uint16_t code, uint8_t additional_len, const char *file, int line); @@ -33,17 +33,17 @@ int _sense_info_build(uint8_t *data, int len, uint32_t not_init_funcs, int _sense_csi_build(uint8_t *data, int len, uint64_t csi, const char *file, int line); */ #define sense_basic_build(sense, key, code, pid, oid) \ - _sense_basic_build(sense, key, code, pid, oid, __FILE__, __LINE__) + _sense_basic_build(sense, key, code, pid, oid, __func__, __LINE__) int _sense_basic_build(uint8_t *sense, uint8_t key, uint16_t code, uint64_t pid, uint64_t oid, const char *file, int line); #define sense_build_sdd(sense, key, code, pid, oid) \ - _sense_build_sdd(sense, key, code, pid, oid, __FILE__, __LINE__) + _sense_build_sdd(sense, key, code, pid, oid, __func__, __LINE__) int _sense_build_sdd(uint8_t *sense, uint8_t key, uint16_t code, uint64_t pid, uint64_t oid, const char *file, int line); #define sense_build_sdd_csi(sense, key, code, pid, oid, csi) \ - _sense_build_sdd_csi(sense, key, code, pid, oid, csi, __FILE__, __LINE__) + _sense_build_sdd_csi(sense, key, code, pid, oid, csi, __func__, __LINE__) int _sense_build_sdd_csi(uint8_t *sense, uint8_t key, uint16_t code, uint64_t pid, uint64_t oid, uint64_t csi, const char *file, int line);