Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package mhvtl for openSUSE:Factory checked in at 2022-01-20 00:12:36 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/mhvtl (Old) and /work/SRC/openSUSE:Factory/.mhvtl.new.1892 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "mhvtl" Thu Jan 20 00:12:36 2022 rev:16 rq:947492 version:1.64_release+835.6beb0aa01437 Changes: -------- --- /work/SRC/openSUSE:Factory/mhvtl/mhvtl.changes 2021-10-08 00:07:28.489898200 +0200 +++ /work/SRC/openSUSE:Factory/.mhvtl.new.1892/mhvtl.changes 2022-01-20 00:13:36.106640553 +0100 @@ -1,0 +2,85 @@ +Tue Jan 18 18:58:52 UTC 2022 - ldun...@suse.com + +- Update to version 1.64_release+835.6beb0aa01437, to fix factory + build issues: + * Fix compiler warning regarding c99 standard + * DIV: Compare CRC32C in big-endian format + * Handle missing drive slots in config file. + * mhvtl.spec: Add preload_tape to the RPM spec file + * Proactively log different CRC seeding options if LBP writes fail + * vtllibrary: Handle library_contents.xx file with missing storage slot sequences + * mhvtl.ko: Fix return type of sysfs_emit() + * DIV: Improve reporting of LBP support + * DIV: Update RS-CRC seed to that in the 'test_crc' + * ssc: Log drive feature list + * DIV: Reduce log noise from LBP function if not enabled + * Update default library generation to LTO6 & LTO8 drives + * mhvtl.ko: Update to use sysfs_emit() rather than scnprintf + * DIV: Write block of data on LBP mis-compare. + * DIV: Set INQUIRY 'protect' bit if LBP is supported. + * Vagrant: Add ability to set headless/gui VM as argument + * DIV: Adding VPD page D5h + * DIV: Add LBP checking on write path + * Refactor check for no compression + * DIV: Add support for LBP in read path + * DIV: Add Mode Page Control Data Protection (0a/f0) + * DIV: Compile time sanity check on CRC routines + * DIV: Add Reed-Solomon CRC + * Vagrant: Yet another typo + * Vagrant: Fix typo in network settings + * Vagrant: Update to include an IP on the internal network + * Config scripts: Don't rely on execute bit being set + * Vagrant: Cleanup install.sh to make a little more robust + * Vagrant install file: whte space cleanup and add st driver for Ubuntu + * kernel Makefile: Add tape_util.o to list of files to cleanup + * tape_util: Fix compiler warning regarding strncpy length. + * Makefile: Add a rule for 'tape_util.o' + * mhvtl.ko: Bump kernel version to 0.18.31 / 2021-11-19 + * mhvtl.ko: flush_kernel_dcache_page function retired + * make clean: Forgot about tape_util.o + * mhvtl.ko: Add ability to specify kernel version in build + * Add vagrant instructions and fix centos installation in vagrant + * Begin to add support for VERIFY_6 op code + * vtlcart: Clean up formatting of 'dump_tape' + * Rename FIXED to FIXED_BLOCK - description of 'fixed' was ambiguous + * preload_tape: Handle media EOM in a more user-friendly way + * preload_tape: Fix sense_buffer global vs local clash + * mhvtl.spec: Silence vtl media files + * Remove temporary files in 'make clean' + * default tape emulation: Add missing media types + * Remove stale email address from man pages. + * preload_tape: Add a man page entry + * preload_tape: Close out the data with a filemark. + * Add new utility 'preload_tape' + * Move writeBlock() to mhvtl_io.c + * Code consolidation: readBlock() to mhvtl_io.c + * Add LTO6 and 7 to man pages as valid cartridge types + * Add: Tape media Code reference. Fix SDLT code + * Comment code : media_type vs medium_density_code + * White-spcae cleanup + * device-conf-generator: respect MHVTL_CONFIG_PATH + * Typo: replace spaces with tabs in comment + * Add: Comment to hp_ultrium.c re: LTO8 and LTO6 compatibility + * Remove LTO6 read ability from LTO8 tapes + * Change LTO7 Number of Tracks to correct value + * Remove erroneous trailing white-space from INSTALL + * Improve a debug log entry to make it more readable + * Improve tape load/unload handling + * Doc: Fix VTLlibrary man page error. Fix: man page typo T10Kb -> T10KB + * Add: Update instructions on sg3-utils name + * Fix: Incorrect sg3_util package name in install instructions + * Fix spelling of 'debugging' + * mhvtl.ko: Bump kernel module version to 0.18.30 / 20211007 + * mhvtl.spec: Updated so it will build on CentOS 8 + * Update Changelog for difference since 1.6-3 release + * systemd: Update Makefile to include systemd install path + * OOM: /proc/<pid>/oom_adj is deprecated. Using oom_score_adj. + * mhvtl.ko: Update function names with 'mhvtl_' prefix + * Update kernel /sys/ location to suit new pseudo name space + Added four patches not yet upstream (but submmtted soon): + * mhvtl-kernel-module-fix-queuecommand-arg-change.patch + * mhvtl-kernel-module-fix-sysfs_emit-decl.patch + * mhvtl-handle-systemd-location-correctly-for-generator.patch + * mhvtl-fix-systemd-generator-dir.patch + +------------------------------------------------------------------- Old: ---- mhvtl-1.63_release+759.35ddb48e5262.tar.xz New: ---- mhvtl-1.64_release+835.6beb0aa01437.tar.xz mhvtl-fix-systemd-generator-dir.patch mhvtl-handle-systemd-location-correctly-for-generator.patch mhvtl-kernel-module-fix-queuecommand-arg-change.patch mhvtl-kernel-module-fix-sysfs_emit-decl.patch ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ mhvtl.spec ++++++ --- /var/tmp/diff_new_pack.tK7jXR/_old 2022-01-20 00:13:36.546640908 +0100 +++ /var/tmp/diff_new_pack.tK7jXR/_new 2022-01-20 00:13:36.550640912 +0100 @@ -1,7 +1,7 @@ # # spec file for package mhvtl # -# Copyright (c) 2021 SUSE LLC +# Copyright (c) 2022 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -26,7 +26,7 @@ Name: mhvtl URL: http://sites.google.com/site/linuxvtl2/ -Version: 1.63_release+759.35ddb48e5262 +Version: 1.64_release+835.6beb0aa01437 Release: 0 Requires: mhvtl-kmp Requires: module-init-tools @@ -35,6 +35,7 @@ BuildRequires: kernel-syms BuildRequires: module-init-tools %endif +BuildRequires: fdupes BuildRequires: modutils BuildRequires: openssl-devel BuildRequires: systemd-rpm-macros @@ -44,10 +45,14 @@ Group: System/Daemons Source: %{name}-%{version}.tar.xz Source2: %{name}.preamble +Patch1: %{name}-kernel-module-fix-queuecommand-arg-change.patch +Patch2: %{name}-kernel-module-fix-sysfs_emit-decl.patch +Patch3: %{name}-handle-systemd-location-correctly-for-generator.patch +Patch4: %{name}-fix-systemd-generator-dir.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build %{?systemd_ordering} -%{?!_systemdgeneratordir:%define _systemdgeneratordir /usr/lib/systemd/system-generators} +%{?!_systemdgeneratordir:%define _systemdgeneratordir %{_prefix}/lib/systemd/system-generators} %if 0%{buildkmp} == 1 %suse_kernel_module_package -n %{name} -p %{S:2} kdump ec2 um @@ -76,10 +81,15 @@ %prep %setup -qn %{name}-%{version} +%patch1 -p1 +%patch2 -p1 +%patch3 -p1 +%patch4 -p1 %build make MHVTL_HOME_PATH=%{mhvtl_home_dir} VERSION=%{version} \ - SYSTEMD_GENERATOR_DIR=%{_systemdgeneratordir} + SYSTEMD_GENERATOR_DIR=%{_systemdgeneratordir} \ + SYSTEMD_SERVICE_DIR=%{_unitdir} %if 0%{buildkmp} == 1 for flavor in %flavors_to_build; do rm -rf obj/$flavor @@ -93,7 +103,9 @@ %install %make_install \ MHVTL_HOME_PATH=%{mhvtl_home_dir} VERSION=%{version}_release LIBDIR=%{_libdir} \ - SYSTEMD_GENERATOR_DIR=%{_systemdgeneratordir} + SYSTEMD_GENERATOR_DIR=%{_systemdgeneratordir} \ + SYSTEMD_SERVICE_DIR=%{_unitdir} +%fdupes %{buildroot}/%{_prefix} %if 0%{buildkmp} == 1 export INSTALL_MOD_PATH=%{buildroot} export INSTALL_MOD_DIR=updates @@ -104,7 +116,8 @@ %endif install -d -m 755 %{buildroot}%{_sbindir} ln -s %{_sbindir}/service %{buildroot}/%{_sbindir}/rc%{name} -install -d -m 755 %{buildroot}/var/lib/%{name} +rm -rf %{buildroot}/%{mhvtl_home_dir} +install -d -m 755 %{buildroot}/%{mhvtl_home_dir} %post %{service_add_post mhvtl-load-modules.service mhvtl.target vtllibrary@.service vtltape@.service} @@ -132,6 +145,7 @@ %{_bindir}/mktape %{_bindir}/edit_tape %{_bindir}/dump_tape +%{_bindir}/preload_tape %{_bindir}/tapeexerciser %{_bindir}/make_vtl_media %{_bindir}/update_device.conf @@ -153,11 +167,11 @@ %{_unitdir}/vtltape@.service %{_unitdir}/vtllibrary@.service %dir %{mhvtl_home_dir} -%ghost %{mhvtl_home_dir}/* %defattr(644,root,root) %{_mandir}/man1/vtlcmd.1%{ext_man} %{_mandir}/man1/vtllibrary.1%{ext_man} %{_mandir}/man1/vtltape.1%{ext_man} +%{_mandir}/man1/preload_tape.1%{ext_man} %{_mandir}/man1/mktape.1%{ext_man} %{_mandir}/man1/make_vtl_media.1%{ext_man} %{_mandir}/man1/edit_tape.1%{ext_man} ++++++ _service ++++++ --- /var/tmp/diff_new_pack.tK7jXR/_old 2022-01-20 00:13:36.578640934 +0100 +++ /var/tmp/diff_new_pack.tK7jXR/_new 2022-01-20 00:13:36.582640937 +0100 @@ -4,8 +4,8 @@ <param name="url">https://github.com/markh794/mhvtl.git</param> <param name="subdir"></param> <param name="filename">mhvtl</param> - <param name="revision">35ddb48e5262</param> - <param name="versionformat">1.6-3_release+@TAG_OFFSET@.%h</param> + <param name="revision">6beb0aa01437</param> + <param name="versionformat">1.6-4_release+@TAG_OFFSET@.%h</param> <param name="match-tag">1.[0-0]-[0-0]_release</param> <param name="changesgenerate">enable</param> </service> ++++++ _servicedata ++++++ --- /var/tmp/diff_new_pack.tK7jXR/_old 2022-01-20 00:13:36.602640954 +0100 +++ /var/tmp/diff_new_pack.tK7jXR/_new 2022-01-20 00:13:36.602640954 +0100 @@ -1,6 +1,6 @@ <servicedata> <service name="tar_scm"> <param name="url">https://github.com/markh794/mhvtl.git</param> - <param name="changesrevision">35ddb48e5262dfe1d9fba987323b425bad0598ac</param></service></servicedata> + <param name="changesrevision">6beb0aa01437ae4092e67a4b6f359ae108ce6d5e</param></service></servicedata> (No newline at EOF) ++++++ mhvtl-1.63_release+759.35ddb48e5262.tar.xz -> mhvtl-1.64_release+835.6beb0aa01437.tar.xz ++++++ ++++ 7946 lines of diff (skipped) ++++++ mhvtl-fix-systemd-generator-dir.patch ++++++ diff --git a/Makefile b/Makefile index b7d487524a7b..b60ff4be00e6 100644 --- a/Makefile +++ b/Makefile @@ -25,6 +25,7 @@ MHVTL_CONFIG_PATH ?= /etc/mhvtl CHECK_CC = cgcc CHECK_CC_FLAGS = '$(CHECK_CC) -Wbitwise -Wno-return-void -no-compile $(ARCH)' SYSTEMD_GENERATOR_DIR ?= /lib/systemd/system-generators +SYSTEMD_SERVICE_DIR ?= /lib/systemd/system ifeq ($(shell whoami),root) ROOTUID = "YES" endif @@ -50,10 +51,13 @@ scripts: patch $(MAKE) -C scripts MHVTL_HOME_PATH=$(MHVTL_HOME_PATH) MHVTL_CONFIG_PATH=$(MHVTL_CONFIG_PATH) etc: patch - $(MAKE) -C etc MHVTL_HOME_PATH=$(MHVTL_HOME_PATH) MHVTL_CONFIG_PATH=$(MHVTL_CONFIG_PATH) + $(MAKE) -C etc MHVTL_HOME_PATH=$(MHVTL_HOME_PATH) MHVTL_CONFIG_PATH=$(MHVTL_CONFIG_PATH) \ + SYSTEM_SERVICE_DIR=$(SYSTEMD_SERVICE_DIR) usr: patch - $(MAKE) -C usr MHVTL_HOME_PATH=$(MHVTL_HOME_PATH) MHVTL_CONFIG_PATH=$(MHVTL_CONFIG_PATH) SYSTEMD_GENERATOR_DIR=$(SYSTEMD_GENERATOR_DIR) + $(MAKE) -C usr MHVTL_HOME_PATH=$(MHVTL_HOME_PATH) MHVTL_CONFIG_PATH=$(MHVTL_CONFIG_PATH) \ + SYSTEMD_GENERATOR_DIR=$(SYSTEMD_GENERATOR_DIR) \ + SYSTEM_SERVICE_DIR=$(SYSTEMD_SERVICE_DIR) kernel: patch $(MAKE) -C kernel @@ -88,7 +92,7 @@ distclean: install: all $(MAKE) -C usr install $(LIBDIR) $(PREFIX) $(DESTDIR) $(SYSTEMD_SERVICE_DIR) $(MAKE) -C scripts install $(PREFIX) $(DESTDIR) - $(MAKE) -i -C etc install $(DESTDIR) $(SYSTEMD_SERVICE_DIR) + $(MAKE) -i -C etc install $(DESTDIR) SYSTEMD_SERVICE_DIR=$(SYSTEMD_SERVICE_DIR) $(MAKE) -C man man $(MAKE) -C man install $(PREFIX) $(DESTDIR) [ -d $(DESTDIR)$(MHVTL_HOME_PATH) ] || mkdir -p $(DESTDIR)$(MHVTL_HOME_PATH) ++++++ mhvtl-handle-systemd-location-correctly-for-generator.patch ++++++ >From 81e607d44da28a9bac4f04ce58e72791f6f8a7d0 Mon Sep 17 00:00:00 2001 From: Lee Duncan <ldun...@suse.com> Date: Tue, 18 Jan 2022 12:31:14 -0800 Subject: [PATCH] Handle systemd location correctly for generator. This now correctly handles the systemd generator dir being in either /lib/system or /usr/lib/systemd. --- Makefile | 2 +- usr/Makefile | 1 + usr/mhvtl-device-conf-generator.c | 29 ++++++++++++++++------------- 3 files changed, 18 insertions(+), 14 deletions(-) diff --git a/Makefile b/Makefile index 6799957272b5..b7d487524a7b 100644 --- a/Makefile +++ b/Makefile @@ -86,7 +86,7 @@ distclean: $(RM) ../$(TAR_FILE) install: all - $(MAKE) -C usr install $(LIBDIR) $(PREFIX) $(DESTDIR) + $(MAKE) -C usr install $(LIBDIR) $(PREFIX) $(DESTDIR) $(SYSTEMD_SERVICE_DIR) $(MAKE) -C scripts install $(PREFIX) $(DESTDIR) $(MAKE) -i -C etc install $(DESTDIR) $(SYSTEMD_SERVICE_DIR) $(MAKE) -C man man diff --git a/usr/Makefile b/usr/Makefile index 0032ffedfbcb..49ff19e73659 100644 --- a/usr/Makefile +++ b/usr/Makefile @@ -40,6 +40,7 @@ CFLAGS += -D_GNU_SOURCE CFLAGS += -DMHVTL_DEBUG CFLAGS += -DMHVTL_HOME_PATH=\"$(MHVTL_HOME_PATH)\" CFLAGS += -DMHVTL_CONFIG_PATH=\"$(MHVTL_CONFIG_PATH)\" +CFLAGS += -DSYSTEMD_SERVICE_DIR=\"$(SYSTEMD_SERVICE_DIR)\" CLFLAGS=-shared ${RPM_OPT_FLAGS} diff --git a/usr/mhvtl-device-conf-generator.c b/usr/mhvtl-device-conf-generator.c index d7db2851ea5e..3504aa6a95d7 100644 --- a/usr/mhvtl-device-conf-generator.c +++ b/usr/mhvtl-device-conf-generator.c @@ -260,42 +260,45 @@ int main(int argc, char **argv) if (debug_mode) printf("DEBUG: scanning libraries ...\n"); for (ip = our_libraries.next; ip != NULL; ip = ip->next) { - const char to_path[] = "/usr/lib/systemd/system/vtllibrary@.service"; - if (asprintf(&path, "%s/%s/vtllibrary@%d.service", working_dir, dirname, ip->num) < 0) { + char *from_path, *to_path; + if ((asprintf(&from_path, "%s/%s/vtllibrary@%d.service", working_dir, dirname, ip->num) < 0) || + (asprintf(&to_path, "%s/vtllibrary@.service", SYSTEMD_SERVICE_DIR) < 0)) { perror("Could not allocate memory (for vtllibrary template symlink)"); exit(1); } if (debug_mode) - (void) fprintf(stderr, "DEBUG: creating symlink: %s => %s\n", path, to_path); - if (symlink(to_path, path) < 0) { + (void) fprintf(stderr, "DEBUG: creating symlink: %s => %s\n", from_path, to_path); + if (symlink(to_path, from_path) < 0) { if (debug_mode) (void) fprintf(stderr, "DEBUG: error: can't create symlink (%d): %s => %s\n", - errno, path, to_path); + errno, from_path, to_path); // clean up? exit(1); } - free(path); + free(from_path); + free(to_path); } if (debug_mode) printf("DEBUG: scanning tapes ...\n"); for (ip = our_tapes.next; ip != NULL; ip = ip->next) { - const char *to_path = "/usr/lib/systemd/system/vtltape@.service"; - if (asprintf(&path, "%s/%s/vtltape@%d.service", working_dir, dirname, ip->num) < 0) { + char *from_path, *to_path; + if ((asprintf(&from_path, "%s/%s/vtltape@%d.service", working_dir, dirname, ip->num) < 0) || + (asprintf(&to_path, "%s/vtltape@.service", SYSTEMD_SERVICE_DIR) < 0)) { perror("Could not allocate memory (for vtltape template symlink)"); exit(1); } if (debug_mode) - (void) fprintf(stderr, "DEBUG: creating symlink: %s => %s\n", path, to_path); - if (symlink(to_path, path) < 0) { + (void) fprintf(stderr, "DEBUG: creating symlink: %s => %s\n", from_path, to_path); + if (symlink(to_path, from_path) < 0) { if (debug_mode) (void) fprintf(stderr, "DEBUG: error: can't create symlink (%d): %s => %s\n", - errno, path, to_path); + errno, from_path, to_path); // clean up? exit(1); } - free(path); + free(from_path); + free(to_path); } - exit(0); } -- 2.26.2 ++++++ mhvtl-kernel-module-fix-queuecommand-arg-change.patch ++++++ From: Lee Duncan <ldun...@suse.com> Date: Tue Jan 18 11:33:07 PST 2022 Subject: [PATCH] mhvtl kernel module: fix queuecommand arg change The kernel now assume scsi_done for the "done" argument to the queue command, so patch our queuecommand routine. Will be submitted upstream. --- diff --git a/kernel/mhvtl.c b/kernel/mhvtl.c index 6ba5d2c3a0ea..099c781b1f52 100644 --- a/kernel/mhvtl.c +++ b/kernel/mhvtl.c @@ -275,8 +275,12 @@ static int mhvtl_change_queue_depth(struct scsi_device *sdev, int qdepth, int reason); #endif #endif -static int mhvtl_queuecommand_lck(struct scsi_cmnd *, - void (*done) (struct scsi_cmnd *)); +static int mhvtl_queuecommand_lck(struct scsi_cmnd * +#if LINUX_VERSION_CODE < KERNEL_VERSION(5,16,0) + , done_funct_t done +#endif + ); + #if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 0, 0) static int mhvtl_b_ioctl(struct scsi_device *, unsigned int, void __user *); #else @@ -593,8 +597,15 @@ static int mhvtl_q_cmd(struct scsi_cmnd *scp, /********************************************************************** * Main interface from SCSI mid level **********************************************************************/ -static int mhvtl_queuecommand_lck(struct scsi_cmnd *SCpnt, done_funct_t done) +static int mhvtl_queuecommand_lck(struct scsi_cmnd *SCpnt +#if LINUX_VERSION_CODE < KERNEL_VERSION(5,16,0) + , done_funct_t done +#endif + ) { +#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,16,0) + void (*done)(struct scsi_cmnd *) = scsi_done; +#endif unsigned char *cmd = (unsigned char *) SCpnt->cmnd; int errsts = 0; struct mhvtl_lu_info *lu = NULL; ++++++ mhvtl-kernel-module-fix-sysfs_emit-decl.patch ++++++ From: Lee Duncan <ldun...@suse.com> Date: Tue Jan 18 11:34:13 PST 2022 Subject: [PATCH] mhvtl kernel module: fix sysfs emit decl Fix the sysfs_emit declaration so that kernels that don't have this function will still compile. Tested on 5.3.18. Will be submitted upstream. --- diff --git a/kernel/backport.h b/kernel/backport.h index 5c03f6e8150f..ef70aef20004 100644 --- a/kernel/backport.h +++ b/kernel/backport.h @@ -49,7 +49,7 @@ static inline struct inode *file_inode(struct file *f) #define HAVE_UNLOCKED_IOCTL 1 #endif -#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 14, 0) +#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 10, 0) /* https://patches.linaro.org/project/stable/patch/20210305120853.392925...@linuxfoundation.org/ */ /** * sysfs_emit - scnprintf equivalent, aware of PAGE_SIZE buffer.