From ac3b1c8eda5e4ee8a4f2b71b587ff14f7bbb6bd6 Mon Sep 17 00:00:00 2001 From: Jeremy Ellington Date: Thu, 27 May 2004 15:51:35 +0000 Subject: [PATCH] moved ipmi_csum to helper, as both lan and lanplus use it. --- ipmitool/src/plugins/lan/lan.c | 7 ------- ipmitool/src/plugins/lan/lan.h | 2 +- 2 files changed, 1 insertion(+), 8 deletions(-) diff --git a/ipmitool/src/plugins/lan/lan.c b/ipmitool/src/plugins/lan/lan.c index 3fb9189..42c676f 100644 --- a/ipmitool/src/plugins/lan/lan.c +++ b/ipmitool/src/plugins/lan/lan.c @@ -428,13 +428,6 @@ ipmi_auth_md5(struct ipmi_session * s, unsigned char * data, int data_len) return digest; } -unsigned char ipmi_csum(unsigned char * d, int s) -{ - unsigned char c = 0; - for (; s > 0; s--, d++) - c += *d; - return -c; -} static struct ipmi_rs * ipmi_lan_poll_recv(struct ipmi_intf * intf) diff --git a/ipmitool/src/plugins/lan/lan.h b/ipmitool/src/plugins/lan/lan.h index a55a7db..d568cfe 100644 --- a/ipmitool/src/plugins/lan/lan.h +++ b/ipmitool/src/plugins/lan/lan.h @@ -60,7 +60,7 @@ #define IPMI_SESSION_PRIV_ADMIN 0x4 #define IPMI_SESSION_PRIV_OEM 0x5 -unsigned char ipmi_csum(unsigned char * d, int s); + struct ipmi_rs * ipmi_lan_send_cmd(struct ipmi_intf * intf, struct ipmi_rq * req); int ipmi_lan_open(struct ipmi_intf * intf);