summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* iscsid: fix logout pdu send failure handlingfix-logoutMike Christie2022-04-201-7/+8
| | | | | | | | | | | | | | | | This fixes a bug where when we send logout pdu we are incorrectly handling it as an error. This was added in https://github.com/open-iscsi/open-iscsi/pull/317 I think there might have been a mistake for which version of that patch got merged because there are some unhandled review comments in the merged code. The patch also fixes some review comments that were given in that review but were not handled when it was merged: 1. No space before "Dropping session" 2. Don't split error messages.
* Merge pull request #340 from gonzoleeman/make-ibft-build-more-stableLee Duncan2022-04-132-1/+23
|\ | | | | Make fwparam_ibft build more reliable.
| * Make fwparam_ibft build more reliable.Lee Duncan2022-04-132-1/+23
|/ | | | | | | | | | | | | | | | This build has lex and bison source files, but they are not normally used to regenerate C files, since that has been done ahead of time, statically, to handle the case when users building the software may not have these tools. But some build systems think the generated C files need to be regenerated because the timestamp on the source and generated files is so close, just because of the order the files were populated in this directory. So we tell the Makefile to only generate C files if those files are missing. This should have no effect, since these files should never need to be regenerated unless we change lex or bison logic.
* Merge pull request #333 from thesamesam/masterLee Duncan2022-04-107-14/+15
|\ | | | | Build system tweaks from downstream
| * libopeniscsiusr: fix version in installed pkgconfig (.pc) fileSam James2022-04-061-1/+1
| | | | | | | | | | | | | | Looks like a typo from libnvme. Previously, the installed .pc file had a blank Version field. Signed-off-by: Sam James <sam@gentoo.org>
| * Makefiles: don't hardcode sed, pkg-configSam James2022-04-062-3/+3
| | | | | | | | | | | | | | | | | | - On my system, sed appears to be at /bin/sed. So, let's allow overriding the location. - Allow different pkg-config paths too (useful for cross). Signed-off-by: Sam James <sam@gentoo.org>
| * Makefiles: respect $(CC) fully (don't hardcode GCC); use $(RM)Sam James2022-04-065-7/+7
| | | | | | | | | | | | | | - Don't hardcode GCC, instead respect the detected CC (or from the environment) - Use $(RM) as the location may vary and we've already done the work to detect it Signed-off-by: Sam James <sam@gentoo.org>
| * iscsiuio: respect LDFLAGS fullySam James2022-04-031-2/+3
| | | | | | | | | | | | | | | | | | | | | | Use LIBS rather than LDFLAGS which ensures automake gets the ordering right (some LDFLAGS values won't work correctly if not placed exactly before libraries). This should functionally work the same as before, just improve compatibility with bits like -Wl,--as-needed. Signed-off-by: Sam James <sam@gentoo.org>
| * iscsiuio: don't clobber LDFLAGS in configure.acSam James2022-04-031-1/+1
| | | | | | | | | | | | | | | | | | The systemd check currently clobbers LDFLAGS from the environment rather than appending to it. But we actually want LIBS here anyway, rather than LDFLAGS. Signed-off-by: Sam James <sam@gentoo.org>
* | Merge pull request #336 from gonzoleeman/use-kernel-initiatorname-if-presentLee Duncan2022-04-102-45/+146
|\ \ | | | | | | Use kernel initiatorname if present
| * | Check for root in iscsi-gen-initiatornameLee Duncan2022-04-082-6/+16
| | | | | | | | | | | | The man page is also updated
| * | utils: remove errant spaces in scriptLee Duncan2022-04-071-5/+5
| | | | | | | | | | | | | | | There were a few spaces accidentally left at the ends of a few lines in iscsi-gen-initiatorname, so remove them.
| * | Use kernel initiatorname when setting local inameLee Duncan2022-04-072-41/+132
|/ / | | | | | | | | | | | | | | | | | | | | Update the iscsi-gen-initatorname script to take its initiator name from the kernel command line, if present. Also, beef up and simplify the error checking. Error messages will now go to stderr, and it is now an error to overwrite the initiatorname file unless the "force" option is set. The man page was updated, as well.
* | Merge pull request #335 from gonzoleeman/latest-build-cleanups-v2Lee Duncan2022-04-056-25/+78
|\ \ | | | | | | Latest build cleanups and bug fixes
| * | Build: install systemd generator file with svc filesLee Duncan2022-04-041-4/+14
| | | | | | | | | | | | | | | | | | | | | Installation of the systemd generator file ibft-rule-generator is added in etc/Makefile to the "install" target, and that target is broken into "install_systemd_service_files", and "install_systemd_generator_files", for caller convenience.
| * | Create an systemd iBFT rule generatorLee Duncan2022-04-041-0/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | When dracut is booted with 'ip=ibft' it will rename the interfaces to "ibft*". This will cause error messages during booting, as later on systemd is trying to rename the ianterfaces again, which doesn't work as the interface is busy. So create a systemd generator for creating a dynamic udev rule to stop udev from renaming that interface.
| * | Build: add RULESDIR to top-level MakefileLee Duncan2022-04-041-1/+2
| | | | | | | | | | | | | | | | | | | | | Commit 9a2d2f2cf391 ("Make DB and ISCSIHOME directories configurable.") added use of RULESDIR in utils/Makefile, but it needs to be passed down from the top-level Makefile, as well, for it to be configurable at build time.
| * | Build: remove redundant definition in utils MakefileLee Duncan2022-04-041-2/+1
| | | | | | | | | | | | We do not need two definitions for "/etc" in utils/Makefile.
| * | Build: add libsystemd CFLAGS for building objectsLee Duncan2022-04-041-0/+1
| | | | | | | | | | | | | | | | | | This is already done for libkod in usr/Makefile, so do the same for libsystemd, even though most times these flags will be empty, that is not always the case.
| * | Build: cleanup libopeniscsiusr/MakefileLee Duncan2022-04-041-6/+6
| | | | | | | | | | | | | | | Do not need redundant slashes in pathnames. Also, install header files with the proper mode.
| * | Remove debug messages from libopeniscsiusr/MakefileLee Duncan2022-04-041-1/+0
| | | | | | | | | | | | | | | Commit 623a81123c494 ("Use pkg-config in Makefiles for newer libraries.") added a debugging echo statement. Remove it.
| * | Build: libopeniscsiusr install should install docsLee Duncan2022-04-041-1/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | We go to all the trouble to generate man pages for all the libopeniscsiusr routines, but we do not install them, so add installing them as part of the "install" target, ut break up that target into 3 sub-targets (install_libs, install_docs, and install_pkg_config) so that callers can choose subsets if they wish.
| * | Build: use upper- vs lower-case variable names correctlyLee Duncan2022-04-041-11/+12
| | | | | | | | | | | | | | | For the files we insall from etc/Makefile, this avoids prepending with DESTDIR twice.
| * | Build: remove unused Makefile HOMEDIR creationLee Duncan2022-04-041-3/+0
|/ / | | | | | | | | The "HOMEDIR" (/etc/iscsi by default) is no referenced in the top-level Makefile, so no need to create it here.
* | Merge pull request #330 from ryancaicse/masterLee Duncan2022-04-031-1/+1
|\ \ | | | | | | Fix a missing-unlocking bug
| * | Fix a missing-unlocking bugryancaicse2022-04-021-1/+1
| | | | | | | | | Fix a missing-unlocking bug in nic_utils.c
* | | Merge pull request #334 from gonzoleeman/fix-destdir-install-for-inameLee Duncan2022-04-033-9/+9
|\ \ \ | |_|/ |/| | Fix destdir install for iname
| * | Be smarter about creating iscsiuio.8 man pageLee Duncan2022-04-032-8/+8
| | | | | | | | | | | | | | | | | | | | | On install we created both usr/share/man/man8/iscsiuio.8 and usr/share/man/man8/iscsiuio.8.gz, since we installed from both iscsiuio/Makefile as well as from doc/Makefile, so get rid of the doc/Makefile version and just insall the gz from iscsiuio.
| * | Use DESTDIR correctly for HOMEDIR and DBROOTLee Duncan2022-04-031-1/+1
|/ / | | | | | | | | | | The top-level Makefile was adding in DESTDIR to HOMEDIR and DBROOT before passing them down to etc, where DESTDIR was being added again.
* | Merge pull request #332 from gonzoleeman/fix-gcc-issue-in-fwparamLee Duncan2022-04-022-7/+18
|\ \ | |/ |/| Fix gcc issues with unused params in fwparam
| * Fix gcc issues with unused params in fwparamLee Duncan2022-04-022-7/+18
|/ | | | | | Moving these files, as done recently, means they now can be compiled with different (more strict) options, so mark unused params as such.
* Merge pull request #328 from gonzoleeman/more-makefile-cleanupLee Duncan2022-04-0119-671/+62
|\ | | | | More makefile cleanup
| * Build: upate "depend" target to include sysdepsLee Duncan2022-03-311-1/+1
| |
| * Remove unused fwparam_ibft.[ch] files in fwparam_ibft.Lee Duncan2022-03-313-654/+5
| | | | | | | | These files are apparently unused, so remove them.
| * Build: cleanup usr Makefile: remove obj files on "clean"Lee Duncan2022-03-311-3/+8
| | | | | | | | | | | | | | Commit 61443d7db7de ("Build: Cleanup fwparam_ibft and sysdeps subdirs." changed the "clean" target in usr/Makefile so that it no longer removed all object files, rather just removing the ones it knows about. But that commit missed some object files.
| * Add a README for fwparam_ibft subdirectory.Lee Duncan2022-03-311-0/+23
| | | | | | | | Help explain some of the mystery of this directory.
| * Build: Cleanup fwparam_ibft and sysdeps subdirs.Lee Duncan2022-03-3118-14/+26
|/ | | | | | | | | | | | This commit moves the "fwparam_ibft" subdirectory from being under "utils" to being under "usr", where its actually used. It also updates usr/Makefile so that it's smarter about how and when to build the fwparam_ibft object files it needs, as well as how to build sysdeps.o. From the top-level Makefile, "make user" will now make the fwparam_ibft files, as needed for the "user" targets, before building iscsid and friends.
* Merge pull request #325 from gonzoleeman/make_etc_iscsi_configurableLee Duncan2022-03-2924-126/+262
|\ | | | | Make etc iscsi configurable
| * Make DB and ISCSIHOME directories configurable.Lee Duncan2022-03-2523-116/+252
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit adds two new top-level build options: one for the "home" directory for open-iscsi called "HOMEDIR", and one for the "database" directory, called "DBROOT". One can now override the defaults of "/etc/iscsi" for either or both of these directories on the make command line. The README and man pages are updated with details about these new options. Some Makefile cleanup/repair was done as well. Installation of the initiatorname.iscsi file, was moved out of the top-level Makefile into the etc subdirectory, and installation of man ages moved from the top-level Makefile to the doc subdirectory. Also, this fixes some issues from commit fd14dd8316b1 ("Clean p Makefile build system."), which incorrectly changed the DESTDIR ariable in the Makefiles. This current commit also fixes the top-level variable names for moving DBROOT and HOMEDIR.
| * Remove no-longer-used Makefile target for subdirLee Duncan2022-03-231-5/+5
| | | | | | | | | | | | Commit fd14dd8316b1 ("Clean up Makefile build system.") cleaned up the Makefiles, but it left install_etc in the top-level Makefile, which is not used. Removed it.
| * Clean up the usage info for iscsidLee Duncan2022-03-231-9/+9
|/ | | | Just a little grammar cleanup.
* Merge pull request #324 from gonzoleeman/cleanup_build_system_and_templatesLee Duncan2022-03-2315-90/+200
|\ | | | | Clean up Makefile build system.
| * Clean up Makefile build system.Lee Duncan2022-03-2015-90/+200
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A major overdue overhaul of the Make layout, including moving lots of lower-level things out of the top-level Makefile into the Makefiles for the appropriate subdirectory, renaming the template files (where @SBINDIR@ gets translated) so that their purpose is more obvious, making the build more idempotent (no need to install a file if it's not newer). Should be no functional change, as no script or C file changed. Main difference from before: now the udev rules gets made and installed by default (as part of "make"/"make install"), and the iscsiuio daemon is now installed for "make install". One should now be able to go into any subdirectory and type "make"/"make install" to build and install the targets from that directory, at least for the etc, utils, and usr subdirectories. This change is in preparation for more template translations coming.
* | Merge pull request #321 from gonzoleeman/fw-login-add-nv-pairs-v2Lee Duncan2022-03-202-11/+77
|\ \ | |/ |/| Firmware login: add nv pairs and default values
| * Update iscsiadm.8 for firmware name/value pairsLee Duncan2022-03-161-2/+9
| | | | | | | | | | | | Add in verbage about "-n"/"-v" options added for iscsiadm firmware login mode. Also, fix one abbreviation.
| * Allow name/value args for firmware logins.Lee Duncan2022-03-161-9/+68
| | | | | | | | | | | | | | | | | | | | | | This adds 2 things to the firmware login mode: first, it adds sane default values for NOP-OUTs (off), login retry max, and type of scan. Lastly, it also gives the caller the ability to set name/value pairs on the command line, which gives the ability to override these new defaults if desired. The output of "iscsiadm -h" was also cleaned up a bit, removing duplicate spaces.
* | Merge pull request #322 from gonzoleeman/make_etc_iscsi_configurable_v2Lee Duncan2022-03-173-25/+28
|\ \ | |/ |/| General Makefile/README cleanup
| * General Makefile/README cleanupLee Duncan2022-03-173-25/+28
|/ | | | | | | Cleaning up the Makefiles, in preperation for adding the ability to move files out of /etc/iscsi more easily. Also, clean up the README file by updating it with help updated help messages, alignment, and those pesky spaces at the ends of lines.
* Merge pull request #320 from gonzoleeman/cleanup-iscsiadm-man-pageLee Duncan2022-03-151-130/+130
|\ | | | | Cleanup iscsiadm man page
| * Cleanup iscsiadm man pageLee Duncan2022-03-151-130/+130
|/ | | | | | Removed duplicate spaces, fixed spellings, reworded some stuff to be more clear, and tried to be consistent about showing keywords in itallics/emphasis.