summaryrefslogtreecommitdiff
path: root/usr.sbin/iscsid
AgeCommit message (Collapse)Author
2024-05-21remove prototypes with no matching function and externs with no varJonathan Gray
partly checked by millert@
2023-03-08Delete obsolete /* ARGSUSED */ lint comments.Philip Guenther
ok miod@ millert@
2022-12-28spelling fixes; from paul tagliamonteJason McIntyre
any parts of his diff not taken are noted on tech
2021-12-13including sys/cdefs.h manually started as a result of netbsd trying toTheo de Raadt
macro-build a replacement for sccsid, and was done without any concern for namespace damage. Unfortunately this practice started infecting other code as others were unaware they didn't need the file. ok millert guenther
2021-04-16Implement a control message to get the state of iscsid. This is usedClaudio Jeker
by iscsictl to poll for completion after reload commands. With this slow session establishment should not cause mount errors during startup. Initial version from Dr Ashton Fagg ashton (at) fagg id au OK dlg@ deraadt@
2021-04-12Spaces, no functional changeClaudio Jeker
2021-01-27these programs (with common ancestry) had a -fno-common problem relatedTheo de Raadt
to privsep_procid. ok mortimer
2019-11-25Honour DEBUGkn
OK claudio dlg
2019-07-03snprintf/vsnprintf return < 0 on error, rather than -1.Theo de Raadt
2017-04-06fix format string found by clang -Wformat-securityGleydson Soares
OK deraadt millert
2017-03-21From a syslog perspective it does not make sense to log fatal andAlexander Bluhm
warn with the same severity. Switch log_warn() to LOG_ERR and keep fatal() at LOG_CRIT. OK reyk@ florian@
2017-01-23copy log.c/h from bgpd.Sebastian Benoit
ok claudio
2016-09-10fix an fd leak in an error pathJonathan Gray
2016-09-02work on making log.c similar in all daemons:Sebastian Benoit
move daemon-local functions into new logmsg.c, and reduce the (mostly whitespace) differences so that log.c's can be diffed easily. ok claudio@
2016-08-16stop including sys/param.h for nitems. define locally as needed.Ted Unangst
ok natano reyk
2016-07-18add format attributes to log functionsSebastian Benoit
ok claudio@
2016-04-05Remove the iterator for control connections unfinished and unused.YASUOKA Masahiko
ok claudio
2016-03-20Currently we have about a 50/50 split over fcntl(n, F_GETFL [,0])Kenneth R Westerback
idioms. Adopt the more concise fcntl(n, F_GETFL) over fcntl(n, F_GETFL, 0) where it is obvious further investigation will not yield and even better way. Obviousness evaluation and ok guenther@
2015-12-05strings.h -> string.h as necessary to prevent implicit declarationmmcc
warnings
2015-12-05Don't check for NULL before free()mmcc
2015-12-02typo in log entrymmcc
2015-07-27use file system path (.Pa) semantic markup macros where appropriate.Igor Sobrado
ok jmc@
2015-01-16move to <limits.h> where possible, annotate <sys/param.h> otherwiseTheo de Raadt
2014-11-23TargetPortalGroupTag is a binary 16-bit value so 0 is allowed.Claudio Jeker
Still not perfect since binary values can also be base64 encoded but one step closer.
2014-11-23Change the error handling a bit to ensure we do not double free the taskClaudio Jeker
by calling conn_task_cleanup() twice (once direct and once via conn_fail()). The error handling needs some more work but at least this fixes the crash found by jasper@
2014-11-23Clear the work in progress PDU before calling the task handler.Claudio Jeker
This ensures that we don't have multiple pointers pointing to the same PDU.
2014-11-03actually use macro argument instead of shadowed variable nameTed Unangst
2014-07-13Set KERN_PROC_NOBROADCASTKILL so that iscsid is not killed by initClaudio Jeker
when terminating multi-user so that we have a chance to sync the file systems mounted via iscsi.
2014-05-10Extend the connection and session FSMs so that connection failure isClaudio Jeker
handled more gracefully. Losing the TCP connection no longer results in an unrecoverable stop requiring a restart of iscsid.
2014-05-10Move the task cleanup from the task fail callback to taskq_cleanup.Claudio Jeker
This makes the one failure callback a lot simpler.
2014-04-21Bind to localAddr if specified and add some XXX comments about stuffClaudio Jeker
that is not prefect yet.
2014-04-21Start passing the initiator and target name in the show command.Claudio Jeker
2014-04-21Redo most of the control message handling. Switch it back to useClaudio Jeker
SOCK_SEQPACKET and provide functions to build the control messages that can also be used by iscsictl.
2014-04-21Handle EAGAIN, ENOBUFS and EINTR a bit better. Ignore them one layer aboveClaudio Jeker
and do not fail and tear down the world when they happen.
2014-04-21It is possible that we can't burst all of the data in the immediate dataClaudio Jeker
part of the write request. In that case R2T requests with be sent for the rest of the data. The amount of data we can send is defined by MaxRecvDataSegmentLength which is per connection and so a bit hackish to read out. In the long run the min() of all connection MaxRecvDataSegmentLength should be stored in the session struct.
2014-04-21Now that we properly negotiate the session params we can enable sendingClaudio Jeker
of immediate data for write commands. This gives a nice 20% performance boost on writes compared to the solicited data transaction we did before.
2014-04-20Introduce some basic stats for the vscsi layer. Just counting the commandsClaudio Jeker
and the bytes we push through vscsi(4).
2014-04-20After doing all of the loging dance to get the target's params it makesClaudio Jeker
sense to merge them into the active set. At least that way we run with the right params and finally do reads and writes that are > 8k.
2014-04-20Use only one style for "return foo;"Claudio Jeker
2014-04-20Move session params initialization to when we start a session and notClaudio Jeker
when it is created. That way the config params from the config file have a chance to stick.
2014-04-20Fix conn_gen_kvp and its caller to fill the kvp array properly (includingClaudio Jeker
the NULL terminator at the end). Now iscsid does proper LoginOperational negotiation (which will bump the MaxRecvDataSegmentLength to 64k)
2014-04-20Cleanup a bit, switch on bcopy to memcpy and move a function a bit upClaudio Jeker
2014-04-19COnveret the bcopy() to memcpy()Claudio Jeker
2014-04-19Replace a magic number.Claudio Jeker
2014-04-07To win the startup race on the control socket we need to listen to it asClaudio Jeker
well only then the connect() call from iscsictl will not fail. Move listen() into the init function and rename control_listen() to control_event_init() since it is now only doing that.
2014-02-17Call control_init() before daemon() so that iscsid && iscsictl reload worksClaudio Jeker
2013-08-14no longer any need to quote macro lines with >9 args;Jason McIntyre
From: Jan Stary
2013-07-16use .Mt for email addresses; from Jan Stary <hans at stare dot cz>; ok jmc@Ingo Schwarze
2013-03-11handle ECONNABORTED errors from accept(). In many code blocks they can beTheo de Raadt
ignored silently and without aborting, much like EINTR and EWOULDBLOCK are. ok's from various maintainers of these directories...
2012-09-26last stage of rfc changes, using consistent Rs/Re blocks, and moving theJason McIntyre
references into a STANDARDS section;