mirror of
https://github.com/novatiq/packages.git
synced 2026-04-30 07:28:39 +01:00
tgt: update to 1.0.77
- update to 1.0.77 - apply patches from Rosen Penev for compatibility with uClibc-ng - add an option for rotation_rate selection Signed-off-by: Maxim Storchak <m.storchak@gmail.com>
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
From ced49c99ef0b120d32bcbb3bb6985ff90833052e Mon Sep 17 00:00:00 2001
|
||||
From: Rosen Penev <rosenp@gmail.com>
|
||||
Date: Tue, 30 Apr 2019 22:34:45 -0700
|
||||
Subject: [PATCH 1/2] iscsi_tcp: Replace deprecated valloc function
|
||||
|
||||
Replaced with posix_memalign as valloc is not available on uClibc.
|
||||
|
||||
Signed-off-by: Rosen Penev <rosenp@gmail.com>
|
||||
---
|
||||
usr/iscsi/iscsi_tcp.c | 5 ++++-
|
||||
1 file changed, 4 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/usr/iscsi/iscsi_tcp.c b/usr/iscsi/iscsi_tcp.c
|
||||
index 536f22e..5762c23 100644
|
||||
--- a/usr/iscsi/iscsi_tcp.c
|
||||
+++ b/usr/iscsi/iscsi_tcp.c
|
||||
@@ -578,7 +578,10 @@ static void iscsi_tcp_free_task(struct iscsi_task *task)
|
||||
|
||||
static void *iscsi_tcp_alloc_data_buf(struct iscsi_connection *conn, size_t sz)
|
||||
{
|
||||
- return valloc(sz);
|
||||
+ void *addr = NULL;
|
||||
+
|
||||
+ posix_memalign(&addr, sysconf(_SC_PAGESIZE), sz);
|
||||
+ return addr;
|
||||
}
|
||||
|
||||
static void iscsi_tcp_free_data_buf(struct iscsi_connection *conn, void *buf)
|
||||
--
|
||||
2.21.0
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
From 23f3bb1ab8311601db03757a6d4538e747364454 Mon Sep 17 00:00:00 2001
|
||||
From: FUJITA Tomonori <fujita.tomonori@gmail.com>
|
||||
Date: Fri, 3 May 2019 19:30:07 +0900
|
||||
Subject: [PATCH 2/2] iscsi_tcp: fix compile warning
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
iscsi/iscsi_tcp.c: In function ‘iscsi_tcp_alloc_data_buf’:
|
||||
iscsi/iscsi_tcp.c:583:2: error: ignoring return value of ‘posix_memalign’, declared with attribute warn_unused_result [-Werror=unused-result]
|
||||
posix_memalign(&addr, sysconf(_SC_PAGESIZE), sz);
|
||||
^
|
||||
|
||||
Signed-off-by: FUJITA Tomonori <fujita.tomonori@gmail.com>
|
||||
---
|
||||
usr/iscsi/iscsi_tcp.c | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/usr/iscsi/iscsi_tcp.c b/usr/iscsi/iscsi_tcp.c
|
||||
index 5762c23..0a076b0 100644
|
||||
--- a/usr/iscsi/iscsi_tcp.c
|
||||
+++ b/usr/iscsi/iscsi_tcp.c
|
||||
@@ -579,8 +579,8 @@ static void iscsi_tcp_free_task(struct iscsi_task *task)
|
||||
static void *iscsi_tcp_alloc_data_buf(struct iscsi_connection *conn, size_t sz)
|
||||
{
|
||||
void *addr = NULL;
|
||||
-
|
||||
- posix_memalign(&addr, sysconf(_SC_PAGESIZE), sz);
|
||||
+ if (posix_memalign(&addr, sysconf(_SC_PAGESIZE), sz) != 0)
|
||||
+ return addr;
|
||||
return addr;
|
||||
}
|
||||
|
||||
--
|
||||
2.21.0
|
||||
|
||||
Reference in New Issue
Block a user