mirror of
https://github.com/siderolabs/extensions.git
synced 2025-08-06 22:37:24 +02:00
feat: update dependencies
``` | Package | Update | Change | |---|---|---| | [https://github.com/qemu/qemu.git](https://togithub.com/qemu/qemu) | patch | `8.2.2` -> `8.2.3` | | [kubernetes/cloud-provider-aws](https://togithub.com/kubernetes/cloud-provider-aws) | minor | `v1.28.1` -> `v1.30.0` | | [tailscale/tailscale](https://togithub.com/tailscale/tailscale) | minor | `1.62.1` -> `1.64.2` | ``` Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
This commit is contained in:
parent
dffe8b9546
commit
2f97116a50
6
.github/workflows/ci.yaml
vendored
6
.github/workflows/ci.yaml
vendored
@ -1,6 +1,6 @@
|
|||||||
# THIS FILE WAS AUTOMATICALLY GENERATED, PLEASE DO NOT EDIT.
|
# THIS FILE WAS AUTOMATICALLY GENERATED, PLEASE DO NOT EDIT.
|
||||||
#
|
#
|
||||||
# Generated on 2024-05-02T15:06:54Z by kres d15226e.
|
# Generated on 2024-05-09T13:22:16Z by kres 1e986af.
|
||||||
|
|
||||||
name: default
|
name: default
|
||||||
concurrency:
|
concurrency:
|
||||||
@ -33,7 +33,7 @@ jobs:
|
|||||||
labels: ${{ steps.retrieve-pr-labels.outputs.result }}
|
labels: ${{ steps.retrieve-pr-labels.outputs.result }}
|
||||||
services:
|
services:
|
||||||
buildkitd:
|
buildkitd:
|
||||||
image: moby/buildkit:v0.13.1
|
image: moby/buildkit:v0.13.2
|
||||||
options: --privileged
|
options: --privileged
|
||||||
ports:
|
ports:
|
||||||
- 1234:1234
|
- 1234:1234
|
||||||
@ -116,7 +116,7 @@ jobs:
|
|||||||
- default
|
- default
|
||||||
services:
|
services:
|
||||||
buildkitd:
|
buildkitd:
|
||||||
image: moby/buildkit:v0.13.1
|
image: moby/buildkit:v0.13.2
|
||||||
options: --privileged
|
options: --privileged
|
||||||
ports:
|
ports:
|
||||||
- 1234:1234
|
- 1234:1234
|
||||||
|
4
.github/workflows/weekly.yaml
vendored
4
.github/workflows/weekly.yaml
vendored
@ -1,6 +1,6 @@
|
|||||||
# THIS FILE WAS AUTOMATICALLY GENERATED, PLEASE DO NOT EDIT.
|
# THIS FILE WAS AUTOMATICALLY GENERATED, PLEASE DO NOT EDIT.
|
||||||
#
|
#
|
||||||
# Generated on 2024-05-02T15:06:54Z by kres d15226e.
|
# Generated on 2024-05-09T13:22:16Z by kres 1e986af.
|
||||||
|
|
||||||
name: weekly
|
name: weekly
|
||||||
concurrency:
|
concurrency:
|
||||||
@ -16,7 +16,7 @@ jobs:
|
|||||||
- pkgs
|
- pkgs
|
||||||
services:
|
services:
|
||||||
buildkitd:
|
buildkitd:
|
||||||
image: moby/buildkit:v0.13.1
|
image: moby/buildkit:v0.13.2
|
||||||
options: --privileged
|
options: --privileged
|
||||||
ports:
|
ports:
|
||||||
- 1234:1234
|
- 1234:1234
|
||||||
|
@ -53,7 +53,7 @@ spec:
|
|||||||
- name: EXTENSIONS_IMAGE_REF
|
- name: EXTENSIONS_IMAGE_REF
|
||||||
defaultValue: $(REGISTRY_AND_USERNAME)/extensions:$(TAG)
|
defaultValue: $(REGISTRY_AND_USERNAME)/extensions:$(TAG)
|
||||||
- name: PKGS
|
- name: PKGS
|
||||||
defaultValue: v1.8.0-alpha.0-12-gedb600a
|
defaultValue: v1.8.0-alpha.0-14-g492638d
|
||||||
- name: PKGS_PREFIX
|
- name: PKGS_PREFIX
|
||||||
defaultValue: ghcr.io/siderolabs
|
defaultValue: ghcr.io/siderolabs
|
||||||
useBldrPkgTagResolver: true
|
useBldrPkgTagResolver: true
|
||||||
|
4
Makefile
4
Makefile
@ -1,6 +1,6 @@
|
|||||||
# THIS FILE WAS AUTOMATICALLY GENERATED, PLEASE DO NOT EDIT.
|
# THIS FILE WAS AUTOMATICALLY GENERATED, PLEASE DO NOT EDIT.
|
||||||
#
|
#
|
||||||
# Generated on 2024-05-07T14:55:03Z by kres d15226e.
|
# Generated on 2024-05-09T17:24:39Z by kres 1e986af.
|
||||||
|
|
||||||
# common variables
|
# common variables
|
||||||
|
|
||||||
@ -52,7 +52,7 @@ COMMON_ARGS += --build-arg=PKGS_PREFIX="$(PKGS_PREFIX)"
|
|||||||
# extra variables
|
# extra variables
|
||||||
|
|
||||||
EXTENSIONS_IMAGE_REF ?= $(REGISTRY_AND_USERNAME)/extensions:$(TAG)
|
EXTENSIONS_IMAGE_REF ?= $(REGISTRY_AND_USERNAME)/extensions:$(TAG)
|
||||||
PKGS ?= v1.8.0-alpha.0-12-gedb600a
|
PKGS ?= v1.8.0-alpha.0-14-g492638d
|
||||||
PKGS_PREFIX ?= ghcr.io/siderolabs
|
PKGS_PREFIX ?= ghcr.io/siderolabs
|
||||||
|
|
||||||
# targets defines all the available targets
|
# targets defines all the available targets
|
||||||
|
4
Pkgfile
4
Pkgfile
@ -4,9 +4,9 @@ format: v1alpha2
|
|||||||
|
|
||||||
vars:
|
vars:
|
||||||
LINUX_FIRMWARE_VERSION: "20240410" # update this when updating PKGS_VERSION in Makefile
|
LINUX_FIRMWARE_VERSION: "20240410" # update this when updating PKGS_VERSION in Makefile
|
||||||
DRBD_DRIVER_VERSION: 9.2.8 # update this when updating PKGS_VERSION in Makefile
|
DRBD_DRIVER_VERSION: 9.2.9 # update this when updating PKGS_VERSION in Makefile
|
||||||
ZFS_DRIVER_VERSION: 2.2.4 # update this when updating PKGS_VERSION in Makefile
|
ZFS_DRIVER_VERSION: 2.2.4 # update this when updating PKGS_VERSION in Makefile
|
||||||
UTIL_LINUX_VERSION: 2.39.3 # update this when updating PKGS_VERSION in Makefile
|
UTIL_LINUX_VERSION: 2.40.1 # update this when updating PKGS_VERSION in Makefile
|
||||||
|
|
||||||
# renovate: datasource=git-tags extractVersion=^libtiprc-(?<version>.*)$ depName=git://linux-nfs.org/~steved/libtirpc
|
# renovate: datasource=git-tags extractVersion=^libtiprc-(?<version>.*)$ depName=git://linux-nfs.org/~steved/libtirpc
|
||||||
LIBTIRPC_VERSION: 1-3-3
|
LIBTIRPC_VERSION: 1-3-3
|
||||||
|
@ -7,8 +7,8 @@ steps:
|
|||||||
- sources:
|
- sources:
|
||||||
- url: https://github.com/kubernetes/cloud-provider-aws/archive/refs/tags/{{ .VERSION }}.tar.gz
|
- url: https://github.com/kubernetes/cloud-provider-aws/archive/refs/tags/{{ .VERSION }}.tar.gz
|
||||||
destination: cloud-provider-aws.tar.gz
|
destination: cloud-provider-aws.tar.gz
|
||||||
sha256: 9d3e20d79facf336a466a1647dff8033007385fb628005c8bf84eb67330ba004
|
sha256: 9558b799c811a09f4f77321558e8a7569ed327c68881c6928e582762320a2f9c
|
||||||
sha512: b9adc389be9301dc4be36c6bf546f354b9f2895cbad13d28d074dbab77f9aecec8d5fd02590d21c2a4acc91b559371adfe9702898c7880d92aea6657b315a539
|
sha512: d9b9c63f2f2b6d9e910650464acc5000ba0cc2e35d0f5f27c4121c5e3cd539682a4b89f80358a5fb2a4c8409e2d82a66c5409e9895c58546c78bbb78b39d96be
|
||||||
env:
|
env:
|
||||||
GOPATH: /go
|
GOPATH: /go
|
||||||
prepare:
|
prepare:
|
||||||
|
@ -3,7 +3,7 @@ GVISOR_VERSION: 20240325.0
|
|||||||
# renovate: datasource=github-releases depName=containerd/stargz-snapshotter
|
# renovate: datasource=github-releases depName=containerd/stargz-snapshotter
|
||||||
STARGZ_SNAPSHOTTER_VERSION: v0.15.1
|
STARGZ_SNAPSHOTTER_VERSION: v0.15.1
|
||||||
# renovate: datasource=github-releases depName=kubernetes/cloud-provider-aws
|
# renovate: datasource=github-releases depName=kubernetes/cloud-provider-aws
|
||||||
CLOUD_PROVIDER_AWS_VERSION: v1.28.1
|
CLOUD_PROVIDER_AWS_VERSION: v1.30.0
|
||||||
# renovate: datasource=github-tags depName=containerd/runwasi
|
# renovate: datasource=github-tags depName=containerd/runwasi
|
||||||
WASMEDGE_VERSION: v0.3.0
|
WASMEDGE_VERSION: v0.3.0
|
||||||
# renovate: datasource=github-tags depName=spinkube/containerd-shim-spin
|
# renovate: datasource=github-tags depName=spinkube/containerd-shim-spin
|
||||||
|
@ -1,2 +1,2 @@
|
|||||||
# update when pkgs version is updated
|
# update when pkgs version is updated
|
||||||
VERSION: "09385d4-{{ .BUILD_ARG_TAG }}"
|
VERSION: "5815ee3-{{ .BUILD_ARG_TAG }}"
|
||||||
|
@ -10,8 +10,8 @@ steps:
|
|||||||
- sources:
|
- sources:
|
||||||
- url: https://download.qemu.org/qemu-{{ .QEMU_VERSION }}.tar.xz
|
- url: https://download.qemu.org/qemu-{{ .QEMU_VERSION }}.tar.xz
|
||||||
destination: qemu.tar.xz
|
destination: qemu.tar.xz
|
||||||
sha256: 847346c1b82c1a54b2c38f6edbd85549edeb17430b7d4d3da12620e2962bc4f3
|
sha256: dc747fb366809455317601c4876bd1f6829a32a23e83fb76e45ab12c2a569964
|
||||||
sha512: dfd2e1305f9e51bfbc90a7738c69336d5f805481a626ea527b971bdfb6dbe6867e5df7461d48d1c22b79be2dc18e057ea9fa36ef593127cd8b262a5c33f1aa41
|
sha512: 18a9a2098b98ed7bcdb045781ef345009aa58c8dba0f8145df366a41e67c302f2789832d5882729d147b49ba371840b1c8541b4276d360a19f2fc4deedb75e8a
|
||||||
prepare:
|
prepare:
|
||||||
- |
|
- |
|
||||||
sed -i 's#$VERSION#{{ .VERSION }}#' /pkg/manifest.yaml
|
sed -i 's#$VERSION#{{ .VERSION }}#' /pkg/manifest.yaml
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
# renovate: datasource=git-tags extractVersion=^v(?<version>.*)$ depName=https://github.com/qemu/qemu.git
|
# renovate: datasource=git-tags extractVersion=^v(?<version>.*)$ depName=https://github.com/qemu/qemu.git
|
||||||
QEMU_VERSION: 8.2.2
|
QEMU_VERSION: 8.2.3
|
||||||
# renovate: datasource=git-tags depName=https://gitlab.gnome.org/GNOME/glib.git
|
# renovate: datasource=git-tags depName=https://gitlab.gnome.org/GNOME/glib.git
|
||||||
GLIB_VERSION: 2.80.0
|
GLIB_VERSION: 2.80.0
|
||||||
# renovate: datasource=github-releases extractVersion=^pcre2-(?<version>.*)$ depName=PCRE2Project/pcre2
|
# renovate: datasource=github-releases extractVersion=^pcre2-(?<version>.*)$ depName=PCRE2Project/pcre2
|
||||||
|
@ -20,6 +20,11 @@ See [Talos Linux documentation](https://www.talos.dev/v1.8/talos-guides/configur
|
|||||||
title = "Component Updates"
|
title = "Component Updates"
|
||||||
description = """
|
description = """
|
||||||
ZFS: 2.2.4
|
ZFS: 2.2.4
|
||||||
|
DRBD: 9.2.9
|
||||||
|
gasket: 5815ee3
|
||||||
|
Tailscale: 1.64.2
|
||||||
|
ecr-credential-provider: 1.30.0
|
||||||
|
qemu-guest-agent: 8.2.3
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
|
||||||
|
@ -9,8 +9,8 @@ steps:
|
|||||||
- sources:
|
- sources:
|
||||||
- url: https://github.com/tailscale/tailscale/archive/refs/tags/v{{ .TAILSCALE_VERSION }}.tar.gz
|
- url: https://github.com/tailscale/tailscale/archive/refs/tags/v{{ .TAILSCALE_VERSION }}.tar.gz
|
||||||
destination: tailscale.tar.gz
|
destination: tailscale.tar.gz
|
||||||
sha256: 22737fae37e971fecdf49d6b741b99988868aa3f1e683e67e14b872a2c49ca1c
|
sha256: e5e46f6b6b716b2c4696dce0b92dc2e36f02b06b7ad9f055042a820ad61b2a47
|
||||||
sha512: ca082e036f3e30a67dce3d0a98142f8241effb598c779c00c761358b8300ce1849926e3400194931e197caea1b3bb79b9e76267d5984f9c2484f3b1db42de132
|
sha512: 2f7d606d689b646e54a1e057f496e27b53aa26cee3c5bbcbd2e75ceb3fb9c37f9852782a075b2ff9dec759e63dba842edf43aace76c58f4bbbba7a425e770218
|
||||||
prepare:
|
prepare:
|
||||||
- |
|
- |
|
||||||
sed -i 's#$VERSION#{{ .VERSION }}#' /pkg/manifest.yaml
|
sed -i 's#$VERSION#{{ .VERSION }}#' /pkg/manifest.yaml
|
||||||
|
@ -1,2 +1,2 @@
|
|||||||
# renovate: datasource=github-releases extractVersion=^v(?<version>.*)$ depName=tailscale/tailscale
|
# renovate: datasource=github-releases extractVersion=^v(?<version>.*)$ depName=tailscale/tailscale
|
||||||
TAILSCALE_VERSION: 1.62.1
|
TAILSCALE_VERSION: 1.64.2
|
||||||
|
@ -2,4 +2,4 @@ module nvidia-container-runtime-wrapper
|
|||||||
|
|
||||||
go 1.22
|
go 1.22
|
||||||
|
|
||||||
require golang.org/x/sys v0.18.0
|
require golang.org/x/sys v0.20.0
|
||||||
|
@ -1,2 +1,2 @@
|
|||||||
golang.org/x/sys v0.18.0 h1:DBdB3niSjOA/O0blCZBqDefyWNYveAYMNF1Wum0DYQ4=
|
golang.org/x/sys v0.20.0 h1:Od9JTbYCk261bKm4M/mw7AklTlFYIa0bIp9BgSm1S8Y=
|
||||||
golang.org/x/sys v0.18.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
|
golang.org/x/sys v0.20.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
|
||||||
|
@ -2,4 +2,4 @@ module nvidia-persistenced-wrapper
|
|||||||
|
|
||||||
go 1.22
|
go 1.22
|
||||||
|
|
||||||
require golang.org/x/sys v0.18.0
|
require golang.org/x/sys v0.20.0
|
||||||
|
@ -1,2 +1,2 @@
|
|||||||
golang.org/x/sys v0.18.0 h1:DBdB3niSjOA/O0blCZBqDefyWNYveAYMNF1Wum0DYQ4=
|
golang.org/x/sys v0.20.0 h1:Od9JTbYCk261bKm4M/mw7AklTlFYIa0bIp9BgSm1S8Y=
|
||||||
golang.org/x/sys v0.18.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
|
golang.org/x/sys v0.20.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
|
||||||
|
@ -2,4 +2,4 @@ module iscsid-wrapper
|
|||||||
|
|
||||||
go 1.22
|
go 1.22
|
||||||
|
|
||||||
require golang.org/x/sys v0.18.0
|
require golang.org/x/sys v0.20.0
|
||||||
|
@ -1,2 +1,2 @@
|
|||||||
golang.org/x/sys v0.18.0 h1:DBdB3niSjOA/O0blCZBqDefyWNYveAYMNF1Wum0DYQ4=
|
golang.org/x/sys v0.20.0 h1:Od9JTbYCk261bKm4M/mw7AklTlFYIa0bIp9BgSm1S8Y=
|
||||||
golang.org/x/sys v0.18.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
|
golang.org/x/sys v0.20.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
|
||||||
|
16
storage/mdadm/patches/fix-monitor-tv_sec.patch
Normal file
16
storage/mdadm/patches/fix-monitor-tv_sec.patch
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
diff --git monitor.c monitor.c
|
||||||
|
index 81537ed..08027ac 100644
|
||||||
|
--- a/monitor.c
|
||||||
|
+++ b/monitor.c
|
||||||
|
@@ -447,9 +447,9 @@ static int read_and_act(struct active_array *a, fd_set *fds)
|
||||||
|
}
|
||||||
|
|
||||||
|
gettimeofday(&tv, NULL);
|
||||||
|
- dprintf("(%d): %ld.%06ld state:%s prev:%s action:%s prev: %s start:%llu\n",
|
||||||
|
+ dprintf("(%d): %lld.%06ld state:%s prev:%s action:%s prev: %s start:%llu\n",
|
||||||
|
a->info.container_member,
|
||||||
|
- tv.tv_sec, tv.tv_usec,
|
||||||
|
+ (long long)tv.tv_sec, (long)tv.tv_usec,
|
||||||
|
array_states[a->curr_state],
|
||||||
|
array_states[a->prev_state],
|
||||||
|
sync_actions[a->curr_action],
|
641
storage/mdadm/patches/lfs64.patch
Normal file
641
storage/mdadm/patches/lfs64.patch
Normal file
@ -0,0 +1,641 @@
|
|||||||
|
needed since https://github.com/bminor/musl/commit/25e6fee27f4a293728dd15b659170e7b9c7db9bc
|
||||||
|
--
|
||||||
|
diff --git a/Grow.c b/Grow.c
|
||||||
|
index 9c6fc95..bb21333 100644
|
||||||
|
--- a/Grow.c
|
||||||
|
+++ b/Grow.c
|
||||||
|
@@ -4260,10 +4260,10 @@ static int grow_backup(struct mdinfo *sra,
|
||||||
|
bsb.magic[15] = '2';
|
||||||
|
for (i = 0; i < dests; i++)
|
||||||
|
if (part)
|
||||||
|
- lseek64(destfd[i], destoffsets[i] +
|
||||||
|
+ lseek(destfd[i], destoffsets[i] +
|
||||||
|
__le64_to_cpu(bsb.devstart2)*512, 0);
|
||||||
|
else
|
||||||
|
- lseek64(destfd[i], destoffsets[i], 0);
|
||||||
|
+ lseek(destfd[i], destoffsets[i], 0);
|
||||||
|
|
||||||
|
rv = save_stripes(sources, offsets, disks, chunk, level, layout,
|
||||||
|
dests, destfd, offset * 512 * odata,
|
||||||
|
@@ -4282,14 +4282,14 @@ static int grow_backup(struct mdinfo *sra,
|
||||||
|
((char*)&bsb.sb_csum2)-((char*)&bsb));
|
||||||
|
|
||||||
|
rv = -1;
|
||||||
|
- if ((unsigned long long)lseek64(destfd[i],
|
||||||
|
+ if ((unsigned long long)lseek(destfd[i],
|
||||||
|
destoffsets[i] - 4096, 0) !=
|
||||||
|
destoffsets[i] - 4096)
|
||||||
|
break;
|
||||||
|
if (write(destfd[i], &bsb, 512) != 512)
|
||||||
|
break;
|
||||||
|
if (destoffsets[i] > 4096) {
|
||||||
|
- if ((unsigned long long)lseek64(destfd[i], destoffsets[i]+stripes*chunk*odata, 0) !=
|
||||||
|
+ if ((unsigned long long)lseek(destfd[i], destoffsets[i]+stripes*chunk*odata, 0) !=
|
||||||
|
destoffsets[i]+stripes*chunk*odata)
|
||||||
|
break;
|
||||||
|
if (write(destfd[i], &bsb, 512) != 512)
|
||||||
|
@@ -4339,7 +4339,7 @@ static int forget_backup(int dests, int *destfd,
|
||||||
|
if (memcmp(bsb.magic, "md_backup_data-2", 16) == 0)
|
||||||
|
bsb.sb_csum2 = bsb_csum((char*)&bsb,
|
||||||
|
((char*)&bsb.sb_csum2)-((char*)&bsb));
|
||||||
|
- if ((unsigned long long)lseek64(destfd[i], destoffsets[i]-4096, 0) !=
|
||||||
|
+ if ((unsigned long long)lseek(destfd[i], destoffsets[i]-4096, 0) !=
|
||||||
|
destoffsets[i]-4096)
|
||||||
|
rv = -1;
|
||||||
|
if (rv == 0 && write(destfd[i], &bsb, 512) != 512)
|
||||||
|
@@ -4367,7 +4367,7 @@ static void validate(int afd, int bfd, unsigned long long offset)
|
||||||
|
*/
|
||||||
|
if (afd < 0)
|
||||||
|
return;
|
||||||
|
- lseek64(bfd, offset - 4096, 0);
|
||||||
|
+ lseek(bfd, offset - 4096, 0);
|
||||||
|
if (read(bfd, &bsb2, 512) != 512)
|
||||||
|
fail("cannot read bsb");
|
||||||
|
if (bsb2.sb_csum != bsb_csum((char*)&bsb2,
|
||||||
|
@@ -4398,12 +4398,12 @@ static void validate(int afd, int bfd, unsigned long long offset)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
- lseek64(bfd, offset, 0);
|
||||||
|
+ lseek(bfd, offset, 0);
|
||||||
|
if ((unsigned long long)read(bfd, bbuf, len) != len) {
|
||||||
|
//printf("len %llu\n", len);
|
||||||
|
fail("read first backup failed");
|
||||||
|
}
|
||||||
|
- lseek64(afd, __le64_to_cpu(bsb2.arraystart)*512, 0);
|
||||||
|
+ lseek(afd, __le64_to_cpu(bsb2.arraystart)*512, 0);
|
||||||
|
if ((unsigned long long)read(afd, abuf, len) != len)
|
||||||
|
fail("read first from array failed");
|
||||||
|
if (memcmp(bbuf, abuf, len) != 0) {
|
||||||
|
@@ -4431,10 +4431,10 @@ static void validate(int afd, int bfd, unsigned long long offset)
|
||||||
|
bbuf = xmalloc(abuflen);
|
||||||
|
}
|
||||||
|
|
||||||
|
- lseek64(bfd, offset+__le64_to_cpu(bsb2.devstart2)*512, 0);
|
||||||
|
+ lseek(bfd, offset+__le64_to_cpu(bsb2.devstart2)*512, 0);
|
||||||
|
if ((unsigned long long)read(bfd, bbuf, len) != len)
|
||||||
|
fail("read second backup failed");
|
||||||
|
- lseek64(afd, __le64_to_cpu(bsb2.arraystart2)*512, 0);
|
||||||
|
+ lseek(afd, __le64_to_cpu(bsb2.arraystart2)*512, 0);
|
||||||
|
if ((unsigned long long)read(afd, abuf, len) != len)
|
||||||
|
fail("read second from array failed");
|
||||||
|
if (memcmp(bbuf, abuf, len) != 0)
|
||||||
|
@@ -4711,7 +4711,7 @@ int Grow_restart(struct supertype *st, struct mdinfo *info, int *fdlist,
|
||||||
|
st->ss->getinfo_super(st, &dinfo, NULL);
|
||||||
|
st->ss->free_super(st);
|
||||||
|
|
||||||
|
- if (lseek64(fd,
|
||||||
|
+ if (lseek(fd,
|
||||||
|
(dinfo.data_offset + dinfo.component_size - 8) <<9,
|
||||||
|
0) < 0) {
|
||||||
|
pr_err("Cannot seek on device %d\n", i);
|
||||||
|
@@ -4811,7 +4811,7 @@ int Grow_restart(struct supertype *st, struct mdinfo *info, int *fdlist,
|
||||||
|
goto nonew; /* No new data here */
|
||||||
|
}
|
||||||
|
}
|
||||||
|
- if (lseek64(fd, __le64_to_cpu(bsb.devstart)*512, 0)< 0) {
|
||||||
|
+ if (lseek(fd, __le64_to_cpu(bsb.devstart)*512, 0)< 0) {
|
||||||
|
second_fail:
|
||||||
|
if (verbose)
|
||||||
|
pr_err("Failed to verify secondary backup-metadata block on %s\n",
|
||||||
|
@@ -4819,7 +4819,7 @@ int Grow_restart(struct supertype *st, struct mdinfo *info, int *fdlist,
|
||||||
|
continue; /* Cannot seek */
|
||||||
|
}
|
||||||
|
/* There should be a duplicate backup superblock 4k before here */
|
||||||
|
- if (lseek64(fd, -4096, 1) < 0 ||
|
||||||
|
+ if (lseek(fd, -4096, 1) < 0 ||
|
||||||
|
read(fd, &bsb2, sizeof(bsb2)) != sizeof(bsb2))
|
||||||
|
goto second_fail; /* Cannot find leading superblock */
|
||||||
|
if (bsb.magic[15] == '1')
|
||||||
|
diff --git a/raid6check.c b/raid6check.c
|
||||||
|
index a8e6005..392cf29 100644
|
||||||
|
--- a/raid6check.c
|
||||||
|
+++ b/raid6check.c
|
||||||
|
@@ -206,7 +206,7 @@ int autorepair(int *disk, unsigned long long start, int chunk_size,
|
||||||
|
for(j = 0; j < (chunk_size >> CHECK_PAGE_BITS); j++) {
|
||||||
|
if(page_to_write[j] == 1) {
|
||||||
|
int slot = block_index_for_slot[disk[j]];
|
||||||
|
- lseek64(source[slot], offsets[slot] + start * chunk_size + j * CHECK_PAGE_SIZE, SEEK_SET);
|
||||||
|
+ lseek(source[slot], offsets[slot] + start * chunk_size + j * CHECK_PAGE_SIZE, SEEK_SET);
|
||||||
|
write_res += write(source[slot],
|
||||||
|
blocks[disk[j]] + j * CHECK_PAGE_SIZE,
|
||||||
|
CHECK_PAGE_SIZE);
|
||||||
|
@@ -279,9 +279,9 @@ int manual_repair(int chunk_size, int syndrome_disks,
|
||||||
|
}
|
||||||
|
|
||||||
|
int write_res1, write_res2;
|
||||||
|
- off64_t seek_res;
|
||||||
|
+ off_t seek_res;
|
||||||
|
|
||||||
|
- seek_res = lseek64(source[fd1],
|
||||||
|
+ seek_res = lseek(source[fd1],
|
||||||
|
offsets[fd1] + start * chunk_size, SEEK_SET);
|
||||||
|
if (seek_res < 0) {
|
||||||
|
fprintf(stderr, "lseek failed for failed_disk1\n");
|
||||||
|
@@ -289,7 +289,7 @@ int manual_repair(int chunk_size, int syndrome_disks,
|
||||||
|
}
|
||||||
|
write_res1 = write(source[fd1], blocks[failed_slot1], chunk_size);
|
||||||
|
|
||||||
|
- seek_res = lseek64(source[fd2],
|
||||||
|
+ seek_res = lseek(source[fd2],
|
||||||
|
offsets[fd2] + start * chunk_size, SEEK_SET);
|
||||||
|
if (seek_res < 0) {
|
||||||
|
fprintf(stderr, "lseek failed for failed_disk2\n");
|
||||||
|
@@ -374,7 +374,7 @@ int check_stripes(struct mdinfo *info, int *source, unsigned long long *offsets,
|
||||||
|
goto exitCheck;
|
||||||
|
}
|
||||||
|
for (i = 0 ; i < raid_disks ; i++) {
|
||||||
|
- off64_t seek_res = lseek64(source[i], offsets[i] + start * chunk_size,
|
||||||
|
+ off_t seek_res = lseek(source[i], offsets[i] + start * chunk_size,
|
||||||
|
SEEK_SET);
|
||||||
|
if (seek_res < 0) {
|
||||||
|
fprintf(stderr, "lseek to source %d failed\n", i);
|
||||||
|
diff --git a/restripe.c b/restripe.c
|
||||||
|
index a7a7229..eec3619 100644
|
||||||
|
--- a/restripe.c
|
||||||
|
+++ b/restripe.c
|
||||||
|
@@ -581,7 +581,7 @@ int save_stripes(int *source, unsigned long long *offsets,
|
||||||
|
raid_disks, level, layout);
|
||||||
|
if (dnum < 0) abort();
|
||||||
|
if (source[dnum] < 0 ||
|
||||||
|
- lseek64(source[dnum],
|
||||||
|
+ lseek(source[dnum],
|
||||||
|
offsets[dnum] + offset, 0) < 0 ||
|
||||||
|
read(source[dnum], buf+disk * chunk_size,
|
||||||
|
chunk_size) != chunk_size) {
|
||||||
|
@@ -754,8 +754,8 @@ int restore_stripes(int *dest, unsigned long long *offsets,
|
||||||
|
raid_disks, level, layout);
|
||||||
|
if (src_buf == NULL) {
|
||||||
|
/* read from file */
|
||||||
|
- if (lseek64(source, read_offset, 0) !=
|
||||||
|
- (off64_t)read_offset) {
|
||||||
|
+ if (lseek(source, read_offset, 0) !=
|
||||||
|
+ (off_t)read_offset) {
|
||||||
|
rv = -1;
|
||||||
|
goto abort;
|
||||||
|
}
|
||||||
|
@@ -816,7 +816,7 @@ int restore_stripes(int *dest, unsigned long long *offsets,
|
||||||
|
}
|
||||||
|
for (i=0; i < raid_disks ; i++)
|
||||||
|
if (dest[i] >= 0) {
|
||||||
|
- if (lseek64(dest[i],
|
||||||
|
+ if (lseek(dest[i],
|
||||||
|
offsets[i]+offset, 0) < 0) {
|
||||||
|
rv = -1;
|
||||||
|
goto abort;
|
||||||
|
@@ -866,7 +866,7 @@ int test_stripes(int *source, unsigned long long *offsets,
|
||||||
|
int disk;
|
||||||
|
|
||||||
|
for (i = 0 ; i < raid_disks ; i++) {
|
||||||
|
- if ((lseek64(source[i], offsets[i]+start, 0) < 0) ||
|
||||||
|
+ if ((lseek(source[i], offsets[i]+start, 0) < 0) ||
|
||||||
|
(read(source[i], stripes[i], chunk_size) !=
|
||||||
|
chunk_size)) {
|
||||||
|
free(q);
|
||||||
|
diff --git a/super-ddf.c b/super-ddf.c
|
||||||
|
index 3f304cd..7b10568 100644
|
||||||
|
--- a/super-ddf.c
|
||||||
|
+++ b/super-ddf.c
|
||||||
|
@@ -816,7 +816,7 @@ static int load_ddf_header(int fd, unsigned long long lba,
|
||||||
|
if (lba >= size-1)
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
- if (lseek64(fd, lba<<9, 0) < 0)
|
||||||
|
+ if (lseek(fd, lba<<9, 0) < 0)
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
if (read(fd, hdr, 512) != 512)
|
||||||
|
@@ -870,7 +870,7 @@ static void *load_section(int fd, struct ddf_super *super, void *buf,
|
||||||
|
else
|
||||||
|
offset += be64_to_cpu(super->active->secondary_lba);
|
||||||
|
|
||||||
|
- if ((unsigned long long)lseek64(fd, offset<<9, 0) != (offset<<9)) {
|
||||||
|
+ if ((unsigned long long)lseek(fd, offset<<9, 0) != (offset<<9)) {
|
||||||
|
if (dofree)
|
||||||
|
free(buf);
|
||||||
|
return NULL;
|
||||||
|
@@ -889,7 +889,7 @@ static int load_ddf_headers(int fd, struct ddf_super *super, char *devname)
|
||||||
|
|
||||||
|
get_dev_size(fd, NULL, &dsize);
|
||||||
|
|
||||||
|
- if (lseek64(fd, dsize-512, 0) < 0) {
|
||||||
|
+ if (lseek(fd, dsize-512, 0) < 0) {
|
||||||
|
if (devname)
|
||||||
|
pr_err("Cannot seek to anchor block on %s: %s\n",
|
||||||
|
devname, strerror(errno));
|
||||||
|
@@ -1691,7 +1691,7 @@ static int copy_metadata_ddf(struct supertype *st, int from, int to)
|
||||||
|
if (!get_dev_size(from, NULL, &dsize))
|
||||||
|
goto err;
|
||||||
|
|
||||||
|
- if (lseek64(from, dsize-512, 0) < 0)
|
||||||
|
+ if (lseek(from, dsize-512, 0) < 0)
|
||||||
|
goto err;
|
||||||
|
if (read(from, buf, 512) != 512)
|
||||||
|
goto err;
|
||||||
|
@@ -1710,8 +1710,8 @@ static int copy_metadata_ddf(struct supertype *st, int from, int to)
|
||||||
|
|
||||||
|
bytes = dsize - offset;
|
||||||
|
|
||||||
|
- if (lseek64(from, offset, 0) < 0 ||
|
||||||
|
- lseek64(to, offset, 0) < 0)
|
||||||
|
+ if (lseek(from, offset, 0) < 0 ||
|
||||||
|
+ lseek(to, offset, 0) < 0)
|
||||||
|
goto err;
|
||||||
|
while (written < bytes) {
|
||||||
|
int n = bytes - written;
|
||||||
|
@@ -3037,7 +3037,7 @@ static int __write_ddf_structure(struct dl *d, struct ddf_super *ddf, __u8 type)
|
||||||
|
header->openflag = 1;
|
||||||
|
header->crc = calc_crc(header, 512);
|
||||||
|
|
||||||
|
- lseek64(fd, sector<<9, 0);
|
||||||
|
+ lseek(fd, sector<<9, 0);
|
||||||
|
if (write(fd, header, 512) < 0)
|
||||||
|
goto out;
|
||||||
|
|
||||||
|
@@ -3101,7 +3101,7 @@ out:
|
||||||
|
header->openflag = 0;
|
||||||
|
header->crc = calc_crc(header, 512);
|
||||||
|
|
||||||
|
- lseek64(fd, sector<<9, 0);
|
||||||
|
+ lseek(fd, sector<<9, 0);
|
||||||
|
if (write(fd, header, 512) < 0)
|
||||||
|
ret = 0;
|
||||||
|
|
||||||
|
@@ -3154,7 +3154,7 @@ static int _write_super_to_disk(struct ddf_super *ddf, struct dl *d)
|
||||||
|
if (!__write_ddf_structure(d, ddf, DDF_HEADER_SECONDARY))
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
- lseek64(fd, (size-1)*512, SEEK_SET);
|
||||||
|
+ lseek(fd, (size-1)*512, SEEK_SET);
|
||||||
|
if (write(fd, &ddf->anchor, 512) < 0)
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
@@ -3909,7 +3909,7 @@ static int store_super_ddf(struct supertype *st, int fd)
|
||||||
|
return 1;
|
||||||
|
memset(buf, 0, 512);
|
||||||
|
|
||||||
|
- lseek64(fd, dsize-512, 0);
|
||||||
|
+ lseek(fd, dsize-512, 0);
|
||||||
|
rc = write(fd, buf, 512);
|
||||||
|
free(buf);
|
||||||
|
if (rc < 0)
|
||||||
|
diff --git a/super-intel.c b/super-intel.c
|
||||||
|
index d5fad10..236e2ee 100644
|
||||||
|
--- a/super-intel.c
|
||||||
|
+++ b/super-intel.c
|
||||||
|
@@ -3092,7 +3092,7 @@ static int read_imsm_migr_rec(int fd, struct intel_super *super)
|
||||||
|
unsigned long long dsize;
|
||||||
|
|
||||||
|
get_dev_size(fd, NULL, &dsize);
|
||||||
|
- if (lseek64(fd, dsize - (sector_size*MIGR_REC_SECTOR_POSITION),
|
||||||
|
+ if (lseek(fd, dsize - (sector_size*MIGR_REC_SECTOR_POSITION),
|
||||||
|
SEEK_SET) < 0) {
|
||||||
|
pr_err("Cannot seek to anchor block: %s\n",
|
||||||
|
strerror(errno));
|
||||||
|
@@ -3283,7 +3283,7 @@ static int write_imsm_migr_rec(struct supertype *st)
|
||||||
|
continue;
|
||||||
|
|
||||||
|
get_dev_size(sd->fd, NULL, &dsize);
|
||||||
|
- if (lseek64(sd->fd, dsize - (MIGR_REC_SECTOR_POSITION *
|
||||||
|
+ if (lseek(sd->fd, dsize - (MIGR_REC_SECTOR_POSITION *
|
||||||
|
sector_size),
|
||||||
|
SEEK_SET) < 0) {
|
||||||
|
pr_err("Cannot seek to anchor block: %s\n",
|
||||||
|
@@ -4404,7 +4404,7 @@ static int load_imsm_mpb(int fd, struct intel_super *super, char *devname)
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
- if (lseek64(fd, dsize - (sector_size * 2), SEEK_SET) < 0) {
|
||||||
|
+ if (lseek(fd, dsize - (sector_size * 2), SEEK_SET) < 0) {
|
||||||
|
if (devname)
|
||||||
|
pr_err("Cannot seek to anchor block on %s: %s\n",
|
||||||
|
devname, strerror(errno));
|
||||||
|
@@ -4472,7 +4472,7 @@ static int load_imsm_mpb(int fd, struct intel_super *super, char *devname)
|
||||||
|
}
|
||||||
|
|
||||||
|
/* read the extended mpb */
|
||||||
|
- if (lseek64(fd, dsize - (sector_size * (2 + sectors)), SEEK_SET) < 0) {
|
||||||
|
+ if (lseek(fd, dsize - (sector_size * (2 + sectors)), SEEK_SET) < 0) {
|
||||||
|
if (devname)
|
||||||
|
pr_err("Cannot seek to extended mpb on %s: %s\n",
|
||||||
|
devname, strerror(errno));
|
||||||
|
@@ -5994,7 +5994,7 @@ static int add_to_super_imsm(struct supertype *st, mdu_disk_info_t *dk,
|
||||||
|
|
||||||
|
/* clear migr_rec when adding disk to container */
|
||||||
|
memset(super->migr_rec_buf, 0, MIGR_REC_BUF_SECTORS*MAX_SECTOR_SIZE);
|
||||||
|
- if (lseek64(fd, size - MIGR_REC_SECTOR_POSITION*member_sector_size,
|
||||||
|
+ if (lseek(fd, size - MIGR_REC_SECTOR_POSITION*member_sector_size,
|
||||||
|
SEEK_SET) >= 0) {
|
||||||
|
if ((unsigned int)write(fd, super->migr_rec_buf,
|
||||||
|
MIGR_REC_BUF_SECTORS*member_sector_size) !=
|
||||||
|
@@ -6219,7 +6219,7 @@ static int write_super_imsm(struct supertype *st, int doclose)
|
||||||
|
unsigned long long dsize;
|
||||||
|
|
||||||
|
get_dev_size(d->fd, NULL, &dsize);
|
||||||
|
- if (lseek64(d->fd, dsize - sector_size,
|
||||||
|
+ if (lseek(d->fd, dsize - sector_size,
|
||||||
|
SEEK_SET) >= 0) {
|
||||||
|
if ((unsigned int)write(d->fd,
|
||||||
|
super->migr_rec_buf,
|
||||||
|
@@ -6302,7 +6302,7 @@ static int write_ppl_header(unsigned long long ppl_sector, int fd, void *buf)
|
||||||
|
|
||||||
|
ppl_hdr->checksum = __cpu_to_le32(~crc32c_le(~0, buf, PPL_HEADER_SIZE));
|
||||||
|
|
||||||
|
- if (lseek64(fd, ppl_sector * 512, SEEK_SET) < 0) {
|
||||||
|
+ if (lseek(fd, ppl_sector * 512, SEEK_SET) < 0) {
|
||||||
|
ret = -errno;
|
||||||
|
perror("Failed to seek to PPL header location");
|
||||||
|
return ret;
|
||||||
|
@@ -6396,7 +6396,7 @@ static int validate_ppl_imsm(struct supertype *st, struct mdinfo *info,
|
||||||
|
|
||||||
|
dprintf("Checking potential PPL at offset: %llu\n", ppl_offset);
|
||||||
|
|
||||||
|
- if (lseek64(d->fd, info->ppl_sector * 512 + ppl_offset,
|
||||||
|
+ if (lseek(d->fd, info->ppl_sector * 512 + ppl_offset,
|
||||||
|
SEEK_SET) < 0) {
|
||||||
|
perror("Failed to seek to PPL header location");
|
||||||
|
ret = -1;
|
||||||
|
@@ -8858,7 +8858,7 @@ static int store_imsm_mpb(int fd, struct imsm_super *mpb)
|
||||||
|
sectors = mpb_sectors(mpb, sector_size) - 1;
|
||||||
|
|
||||||
|
/* write the extended mpb to the sectors preceeding the anchor */
|
||||||
|
- if (lseek64(fd, dsize - (sector_size * (2 + sectors)),
|
||||||
|
+ if (lseek(fd, dsize - (sector_size * (2 + sectors)),
|
||||||
|
SEEK_SET) < 0)
|
||||||
|
return 1;
|
||||||
|
|
||||||
|
@@ -8868,7 +8868,7 @@ static int store_imsm_mpb(int fd, struct imsm_super *mpb)
|
||||||
|
}
|
||||||
|
|
||||||
|
/* first block is stored on second to last sector of the disk */
|
||||||
|
- if (lseek64(fd, dsize - (sector_size * 2), SEEK_SET) < 0)
|
||||||
|
+ if (lseek(fd, dsize - (sector_size * 2), SEEK_SET) < 0)
|
||||||
|
return 1;
|
||||||
|
|
||||||
|
if ((unsigned int)write(fd, buf, sector_size) != sector_size)
|
||||||
|
@@ -11058,7 +11058,7 @@ int recover_backup_imsm(struct supertype *st, struct mdinfo *info)
|
||||||
|
skipped_disks++;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
- if (lseek64(dl_disk->fd, read_offset, SEEK_SET) < 0) {
|
||||||
|
+ if (lseek(dl_disk->fd, read_offset, SEEK_SET) < 0) {
|
||||||
|
pr_err("Cannot seek to block: %s\n",
|
||||||
|
strerror(errno));
|
||||||
|
skipped_disks++;
|
||||||
|
@@ -11070,7 +11070,7 @@ int recover_backup_imsm(struct supertype *st, struct mdinfo *info)
|
||||||
|
skipped_disks++;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
- if (lseek64(dl_disk->fd, write_offset, SEEK_SET) < 0) {
|
||||||
|
+ if (lseek(dl_disk->fd, write_offset, SEEK_SET) < 0) {
|
||||||
|
pr_err("Cannot seek to block: %s\n",
|
||||||
|
strerror(errno));
|
||||||
|
skipped_disks++;
|
||||||
|
@@ -12320,7 +12320,7 @@ static int imsm_manage_reshape(
|
||||||
|
unsigned long long dsize;
|
||||||
|
|
||||||
|
get_dev_size(d->fd, NULL, &dsize);
|
||||||
|
- if (lseek64(d->fd, dsize - MIGR_REC_SECTOR_POSITION*sector_size,
|
||||||
|
+ if (lseek(d->fd, dsize - MIGR_REC_SECTOR_POSITION*sector_size,
|
||||||
|
SEEK_SET) >= 0) {
|
||||||
|
if ((unsigned int)write(d->fd, super->migr_rec_buf,
|
||||||
|
MIGR_REC_BUF_SECTORS*sector_size) !=
|
||||||
|
@@ -12476,7 +12476,7 @@ static int validate_internal_bitmap_for_drive(struct supertype *st,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
- if (lseek64(fd, offset * super->sector_size, SEEK_SET) < 0)
|
||||||
|
+ if (lseek(fd, offset * super->sector_size, SEEK_SET) < 0)
|
||||||
|
goto abort;
|
||||||
|
if (read(fd, read_buf, IMSM_BITMAP_HEADER_SIZE) !=
|
||||||
|
IMSM_BITMAP_HEADER_SIZE)
|
||||||
|
@@ -12605,7 +12605,7 @@ static int locate_bitmap_imsm(struct supertype *st, int fd, int node_num)
|
||||||
|
offset = get_bitmap_header_sector(super, super->current_vol);
|
||||||
|
dprintf("bitmap header offset is %llu\n", offset);
|
||||||
|
|
||||||
|
- lseek64(fd, offset << 9, 0);
|
||||||
|
+ lseek(fd, offset << 9, 0);
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
@@ -12659,7 +12659,7 @@ static int write_init_bitmap_imsm(struct supertype *st, int fd,
|
||||||
|
return -1;
|
||||||
|
memset(buf, 0xFF, MAX_SECTOR_SIZE);
|
||||||
|
offset = get_bitmap_sector(super, vol_idx);
|
||||||
|
- lseek64(fd, offset << 9, 0);
|
||||||
|
+ lseek(fd, offset << 9, 0);
|
||||||
|
while (written < IMSM_BITMAP_AREA_SIZE) {
|
||||||
|
to_write = IMSM_BITMAP_AREA_SIZE - written;
|
||||||
|
if (to_write > MAX_SECTOR_SIZE)
|
||||||
|
diff --git a/super0.c b/super0.c
|
||||||
|
index b79b97a..74bb418 100644
|
||||||
|
--- a/super0.c
|
||||||
|
+++ b/super0.c
|
||||||
|
@@ -327,12 +327,12 @@ static int copy_metadata0(struct supertype *st, int from, int to)
|
||||||
|
|
||||||
|
offset *= 512;
|
||||||
|
|
||||||
|
- if (lseek64(from, offset, 0) < 0LL)
|
||||||
|
+ if (lseek(from, offset, 0) < 0LL)
|
||||||
|
goto err;
|
||||||
|
if (read(from, buf, bufsize) != bufsize)
|
||||||
|
goto err;
|
||||||
|
|
||||||
|
- if (lseek64(to, offset, 0) < 0LL)
|
||||||
|
+ if (lseek(to, offset, 0) < 0LL)
|
||||||
|
goto err;
|
||||||
|
super = buf;
|
||||||
|
if (super->md_magic != MD_SB_MAGIC ||
|
||||||
|
@@ -862,7 +862,7 @@ static int store_super0(struct supertype *st, int fd)
|
||||||
|
offset = dsize/512 - 8*2;
|
||||||
|
offset &= ~(4*2-1);
|
||||||
|
offset *= 512;
|
||||||
|
- if (lseek64(fd, offset, 0)< 0LL)
|
||||||
|
+ if (lseek(fd, offset, 0)< 0LL)
|
||||||
|
ret = 3;
|
||||||
|
else if (write(fd, st->other, 1024) != 1024)
|
||||||
|
ret = 4;
|
||||||
|
@@ -877,7 +877,7 @@ static int store_super0(struct supertype *st, int fd)
|
||||||
|
|
||||||
|
offset *= 512;
|
||||||
|
|
||||||
|
- if (lseek64(fd, offset, 0)< 0LL)
|
||||||
|
+ if (lseek(fd, offset, 0)< 0LL)
|
||||||
|
return 3;
|
||||||
|
|
||||||
|
if (write(fd, super, sizeof(*super)) != sizeof(*super))
|
||||||
|
@@ -1004,7 +1004,7 @@ static int load_super0(struct supertype *st, int fd, char *devname)
|
||||||
|
|
||||||
|
offset *= 512;
|
||||||
|
|
||||||
|
- if (lseek64(fd, offset, 0)< 0LL) {
|
||||||
|
+ if (lseek(fd, offset, 0)< 0LL) {
|
||||||
|
if (devname)
|
||||||
|
pr_err("Cannot seek to superblock on %s: %s\n",
|
||||||
|
devname, strerror(errno));
|
||||||
|
@@ -1189,7 +1189,7 @@ static int locate_bitmap0(struct supertype *st, int fd, int node_num)
|
||||||
|
|
||||||
|
offset += MD_SB_BYTES;
|
||||||
|
|
||||||
|
- lseek64(fd, offset, 0);
|
||||||
|
+ lseek(fd, offset, 0);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
@@ -1214,7 +1214,7 @@ static int write_bitmap0(struct supertype *st, int fd, enum bitmap_update update
|
||||||
|
|
||||||
|
offset *= 512;
|
||||||
|
|
||||||
|
- if (lseek64(fd, offset + 4096, 0)< 0LL)
|
||||||
|
+ if (lseek(fd, offset + 4096, 0)< 0LL)
|
||||||
|
return 3;
|
||||||
|
|
||||||
|
if (posix_memalign(&buf, 4096, 4096))
|
||||||
|
diff --git a/super1.c b/super1.c
|
||||||
|
index a12a5bc..4e098b0 100644
|
||||||
|
--- a/super1.c
|
||||||
|
+++ b/super1.c
|
||||||
|
@@ -761,7 +761,7 @@ static int copy_metadata1(struct supertype *st, int from, int to)
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
|
- if (lseek64(from, sb_offset << 9, 0) < 0LL)
|
||||||
|
+ if (lseek(from, sb_offset << 9, 0) < 0LL)
|
||||||
|
goto err;
|
||||||
|
if (read(from, buf, bufsize) != bufsize)
|
||||||
|
goto err;
|
||||||
|
@@ -775,7 +775,7 @@ static int copy_metadata1(struct supertype *st, int from, int to)
|
||||||
|
calc_sb_1_csum(sb) != super.sb_csum)
|
||||||
|
goto err;
|
||||||
|
|
||||||
|
- if (lseek64(to, sb_offset << 9, 0) < 0LL)
|
||||||
|
+ if (lseek(to, sb_offset << 9, 0) < 0LL)
|
||||||
|
goto err;
|
||||||
|
if (write(to, buf, bufsize) != bufsize)
|
||||||
|
goto err;
|
||||||
|
@@ -791,9 +791,9 @@ static int copy_metadata1(struct supertype *st, int from, int to)
|
||||||
|
|
||||||
|
bitmap_offset += (int32_t)__le32_to_cpu(super.bitmap_offset);
|
||||||
|
|
||||||
|
- if (lseek64(from, bitmap_offset<<9, 0) < 0)
|
||||||
|
+ if (lseek(from, bitmap_offset<<9, 0) < 0)
|
||||||
|
goto err;
|
||||||
|
- if (lseek64(to, bitmap_offset<<9, 0) < 0)
|
||||||
|
+ if (lseek(to, bitmap_offset<<9, 0) < 0)
|
||||||
|
goto err;
|
||||||
|
|
||||||
|
for (written = 0; written < bytes ; ) {
|
||||||
|
@@ -832,9 +832,9 @@ static int copy_metadata1(struct supertype *st, int from, int to)
|
||||||
|
|
||||||
|
bb_offset += (int32_t)__le32_to_cpu(super.bblog_offset);
|
||||||
|
|
||||||
|
- if (lseek64(from, bb_offset<<9, 0) < 0)
|
||||||
|
+ if (lseek(from, bb_offset<<9, 0) < 0)
|
||||||
|
goto err;
|
||||||
|
- if (lseek64(to, bb_offset<<9, 0) < 0)
|
||||||
|
+ if (lseek(to, bb_offset<<9, 0) < 0)
|
||||||
|
goto err;
|
||||||
|
|
||||||
|
for (written = 0; written < bytes ; ) {
|
||||||
|
@@ -940,7 +940,7 @@ static int examine_badblocks_super1(struct supertype *st, int fd, char *devname)
|
||||||
|
offset = __le64_to_cpu(sb->super_offset) +
|
||||||
|
(int)__le32_to_cpu(sb->bblog_offset);
|
||||||
|
offset <<= 9;
|
||||||
|
- if (lseek64(fd, offset, 0) < 0) {
|
||||||
|
+ if (lseek(fd, offset, 0) < 0) {
|
||||||
|
pr_err("Cannot seek to bad-blocks list\n");
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
@@ -1797,7 +1797,7 @@ static int store_super1(struct supertype *st, int fd)
|
||||||
|
abort();
|
||||||
|
}
|
||||||
|
|
||||||
|
- if (lseek64(fd, sb_offset << 9, 0)< 0LL)
|
||||||
|
+ if (lseek(fd, sb_offset << 9, 0)< 0LL)
|
||||||
|
return 3;
|
||||||
|
|
||||||
|
sbsize = ROUND_UP(sizeof(*sb) + 2 * __le32_to_cpu(sb->max_dev), 512);
|
||||||
|
@@ -1866,7 +1866,7 @@ static int write_init_ppl1(struct supertype *st, struct mdinfo *info, int fd)
|
||||||
|
sizeof(sb->set_uuid)));
|
||||||
|
ppl_hdr->checksum = __cpu_to_le32(~crc32c_le(~0, buf, PPL_HEADER_SIZE));
|
||||||
|
|
||||||
|
- if (lseek64(fd, info->ppl_sector * 512, SEEK_SET) < 0) {
|
||||||
|
+ if (lseek(fd, info->ppl_sector * 512, SEEK_SET) < 0) {
|
||||||
|
ret = errno;
|
||||||
|
perror("Failed to seek to PPL header location");
|
||||||
|
}
|
||||||
|
@@ -1911,7 +1911,7 @@ static int write_empty_r5l_meta_block(struct supertype *st, int fd)
|
||||||
|
crc = crc32c_le(crc, (void *)mb, META_BLOCK_SIZE);
|
||||||
|
mb->checksum = crc;
|
||||||
|
|
||||||
|
- if (lseek64(fd, __le64_to_cpu(sb->data_offset) * 512, 0) < 0LL) {
|
||||||
|
+ if (lseek(fd, __le64_to_cpu(sb->data_offset) * 512, 0) < 0LL) {
|
||||||
|
pr_err("cannot seek to offset of the meta block\n");
|
||||||
|
goto fail_to_write;
|
||||||
|
}
|
||||||
|
@@ -2268,7 +2268,7 @@ static int load_super1(struct supertype *st, int fd, char *devname)
|
||||||
|
return -EINVAL;
|
||||||
|
}
|
||||||
|
|
||||||
|
- if (lseek64(fd, sb_offset << 9, 0)< 0LL) {
|
||||||
|
+ if (lseek(fd, sb_offset << 9, 0)< 0LL) {
|
||||||
|
if (devname)
|
||||||
|
pr_err("Cannot seek to superblock on %s: %s\n",
|
||||||
|
devname, strerror(errno));
|
||||||
|
@@ -2639,7 +2639,7 @@ static int locate_bitmap1(struct supertype *st, int fd, int node_num)
|
||||||
|
}
|
||||||
|
if (mustfree)
|
||||||
|
free(sb);
|
||||||
|
- lseek64(fd, offset<<9, 0);
|
||||||
|
+ lseek(fd, offset<<9, 0);
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
diff --git a/swap_super.c b/swap_super.c
|
||||||
|
index b6db574..9c39aff 100644
|
||||||
|
--- a/swap_super.c
|
||||||
|
+++ b/swap_super.c
|
||||||
|
@@ -16,7 +16,7 @@
|
||||||
|
|
||||||
|
#define MD_NEW_SIZE_SECTORS(x) ((x & ~(MD_RESERVED_SECTORS - 1)) - MD_RESERVED_SECTORS)
|
||||||
|
|
||||||
|
-extern long long lseek64(int, long long, int);
|
||||||
|
+extern long long lseek(int, long long, int);
|
||||||
|
|
||||||
|
int main(int argc, char *argv[])
|
||||||
|
{
|
||||||
|
@@ -38,8 +38,8 @@ int main(int argc, char *argv[])
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
offset = MD_NEW_SIZE_SECTORS(size) * 512LL;
|
||||||
|
- if (lseek64(fd, offset, 0) < 0LL) {
|
||||||
|
- perror("lseek64");
|
||||||
|
+ if (lseek(fd, offset, 0) < 0LL) {
|
||||||
|
+ perror("lseek");
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
if (read(fd, super, 4096) != 4096) {
|
||||||
|
@@ -68,8 +68,8 @@ int main(int argc, char *argv[])
|
||||||
|
super[32*4+10*4 +i] = t;
|
||||||
|
}
|
||||||
|
|
||||||
|
- if (lseek64(fd, offset, 0) < 0LL) {
|
||||||
|
- perror("lseek64");
|
||||||
|
+ if (lseek(fd, offset, 0) < 0LL) {
|
||||||
|
+ perror("lseek");
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
if (write(fd, super, 4096) != 4096) {
|
||||||
|
diff --git a/util.c b/util.c
|
||||||
|
index 3d05d07..6109fd4 100644
|
||||||
|
--- a/util.c
|
||||||
|
+++ b/util.c
|
||||||
|
@@ -2344,7 +2344,7 @@ int zero_disk_range(int fd, unsigned long long sector, size_t count)
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
- if (lseek64(fd, sector * 512, SEEK_SET) < 0) {
|
||||||
|
+ if (lseek(fd, sector * 512, SEEK_SET) < 0) {
|
||||||
|
ret = -errno;
|
||||||
|
pr_err("Failed to seek offset for zeroing\n");
|
||||||
|
goto out;
|
10
storage/mdadm/patches/mdadm-include-sysmacros.patch
Normal file
10
storage/mdadm/patches/mdadm-include-sysmacros.patch
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
--- a/mdadm.h
|
||||||
|
+++ b/mdadm.h
|
||||||
|
@@ -34,6 +34,7 @@
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include <sys/types.h>
|
||||||
|
+#include <sys/sysmacros.h>
|
||||||
|
#include <sys/stat.h>
|
||||||
|
#include <stdint.h>
|
||||||
|
#include <stdlib.h>
|
13
storage/mdadm/patches/no-werror.patch
Normal file
13
storage/mdadm/patches/no-werror.patch
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
diff --git a/Makefile b/Makefile
|
||||||
|
index 5fd7f16..5095a42 100644
|
||||||
|
--- a/Makefile
|
||||||
|
+++ b/Makefile
|
||||||
|
@@ -50,7 +50,7 @@ ifeq ($(origin CC),default)
|
||||||
|
CC := $(CROSS_COMPILE)gcc
|
||||||
|
endif
|
||||||
|
CXFLAGS ?= -ggdb
|
||||||
|
-CWFLAGS = -Wall -Werror -Wstrict-prototypes -Wextra -Wno-unused-parameter
|
||||||
|
+CWFLAGS = -Wall -Wstrict-prototypes -Wextra -Wno-unused-parameter
|
||||||
|
ifdef WARN_UNUSED
|
||||||
|
CWFLAGS += -Wp,-D_FORTIFY_SOURCE=2 -O3
|
||||||
|
endif
|
@ -16,6 +16,11 @@ steps:
|
|||||||
sed -i 's#$VERSION#{{ .VERSION }}#' /pkg/manifest.yaml
|
sed -i 's#$VERSION#{{ .VERSION }}#' /pkg/manifest.yaml
|
||||||
- |
|
- |
|
||||||
tar -xzf mdadm.tar.gz --strip-components=1
|
tar -xzf mdadm.tar.gz --strip-components=1
|
||||||
|
- |
|
||||||
|
patch -p1 < /pkg/patches/lfs64.patch
|
||||||
|
patch -p1 < /pkg/patches/fix-monitor-tv_sec.patch
|
||||||
|
patch -p1 < /pkg/patches/mdadm-include-sysmacros.patch
|
||||||
|
patch -p1 < /pkg/patches/no-werror.patch
|
||||||
- |
|
- |
|
||||||
patch -p1 < /pkg/patches/exit-gracefully-when-md-device-not-found.patch
|
patch -p1 < /pkg/patches/exit-gracefully-when-md-device-not-found.patch
|
||||||
patch -p1 < /pkg/patches/sha1-includes.diff
|
patch -p1 < /pkg/patches/sha1-includes.diff
|
||||||
|
@ -7,8 +7,8 @@ steps:
|
|||||||
- sources:
|
- sources:
|
||||||
- url: https://www.kernel.org/pub/linux/utils/util-linux/v{{ regexReplaceAll ".\\d+$" .UTIL_LINUX_VERSION "${1}" }}/util-linux-{{ regexReplaceAll "\\.0$" .UTIL_LINUX_VERSION "${1}" }}.tar.xz
|
- url: https://www.kernel.org/pub/linux/utils/util-linux/v{{ regexReplaceAll ".\\d+$" .UTIL_LINUX_VERSION "${1}" }}/util-linux-{{ regexReplaceAll "\\.0$" .UTIL_LINUX_VERSION "${1}" }}.tar.xz
|
||||||
destination: util-linux.tar.xz
|
destination: util-linux.tar.xz
|
||||||
sha256: 7b6605e48d1a49f43cc4b4cfc59f313d0dd5402fa40b96810bd572e167dfed0f
|
sha256: 59e676aa53ccb44b6c39f0ffe01a8fa274891c91bef1474752fad92461def24f
|
||||||
sha512: a2de1672f06ca5d2d431db1265a8499808770c3781019ec4a3a40170df4685826d8e3ca120841dcc5df4681ca8c935a993317bd0dc70465b21bf8e0efef65afa
|
sha512: 58ec6eb41d4b6bfc544a80e95c71b5f3798ab4d2a9435d3ee9e5edd56f9b3f09bcb154bdd70e002dc018938937e2e946ae731dcda0f86b362fc43423689e41fc
|
||||||
prepare:
|
prepare:
|
||||||
- |
|
- |
|
||||||
tar -xJf util-linux.tar.xz --strip-components=1
|
tar -xJf util-linux.tar.xz --strip-components=1
|
||||||
|
Loading…
Reference in New Issue
Block a user