From nobody Fri May 03 15:20:53 2024 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4VWDz22ps7z5KBVX; Fri, 3 May 2024 15:21:02 +0000 (UTC) (envelope-from SRS0=a8w7=MG=klop.ws=ronald-lists@realworks.nl) Received: from smtp-relay-int.realworks.nl (smtp-relay-int.realworks.nl [194.109.157.24]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4VWDz14RgBz53rp; Fri, 3 May 2024 15:21:01 +0000 (UTC) (envelope-from SRS0=a8w7=MG=klop.ws=ronald-lists@realworks.nl) Authentication-Results: mx1.freebsd.org; none Date: Fri, 3 May 2024 17:20:53 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=klop.ws; s=rw2; t=1714749653; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=57ilmqu7t0zpke0r9u442/dpjzoUW5yskQd9C6m3NrM=; b=ZEb581XZDEngR6AjY/t5LTvOkr+e61RGdKwPHnJj9UB5RDRVyz4ToDKR7RcE/8DqonQ3v0 RF+t0EArwlyr9CTwaQmBBhiaww7HtCFUMyu5mxYx8afAj+gukLXn6IGyFxGQ/5keTRU9HI 5sEq1KQA/xYqKr9Rktevhy9rPJDzg6VnXv5naUYtcE8HG7PyYPOvTIzNGIxpWb9RD5GR37 XamM8i3XuTbt72AaHVSUQrpdlcUJVGutHgHEv7QjiAkDLakULUv0yov6fog2d1Oji9Jing ff343ByzourPKeHR717J8xx3eiZ9fSkE2lUd6HSOPUWgnx63BK6W86kL1DfgHw== From: Ronald Klop To: Warner Losh Cc: dev-commits-src-all@FreeBSD.org, src-committers@FreeBSD.org, dev-commits-src-main@FreeBSD.org Message-ID: <1010899452.10421.1714749653185@localhost> In-Reply-To: <202405031447.443ElgZj051266@gitrepo.freebsd.org> References: <202405031447.443ElgZj051266@gitrepo.freebsd.org> Subject: Re: git: 12117d0e9314 - main - da: Update trim stats for WRITE SAME and ATA TRIM List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_10420_1216642803.1714749653117" X-Mailer: Realworks (701.18) Importance: Normal X-Priority: 3 (Normal) X-Spamd-Bar: ---- X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:3265, ipnet:194.109.0.0/16, country:NL] X-Rspamd-Queue-Id: 4VWDz14RgBz53rp ------=_Part_10420_1216642803.1714749653117 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Are you sure you used the right PR? https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=277637 "[NEW PORT] security/enc: Modern and friendly CLI alternative to GnuPG" Regards, Ronald. Van: Warner Losh Datum: vrijdag, 3 mei 2024 16:47 Aan: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Onderwerp: git: 12117d0e9314 - main - da: Update trim stats for WRITE SAME and ATA TRIM > > The branch main has been updated by imp: > > URL: https://cgit.FreeBSD.org/src/commit/?id=12117d0e9314d1706508386c1c49ace2de578b31 > > commit 12117d0e9314d1706508386c1c49ace2de578b31 > Author: Matthew Grooms > AuthorDate: 2024-05-03 14:41:05 +0000 > Commit: Warner Losh > CommitDate: 2024-05-03 14:46:59 +0000 > > da: Update trim stats for WRITE SAME and ATA TRIM > > The scsi UNMAP path updated trim stats in the da sysctl, but the ATA > TRIM passthru and WRITE SAME paths did not. Add code so they do. > > PR: 277637 > Reviewed by: imp (tweaked WS path to update ranges) > --- > sys/cam/scsi/scsi_da.c | 6 ++++++ > 1 file changed, 6 insertions(+) > > diff --git a/sys/cam/scsi/scsi_da.c b/sys/cam/scsi/scsi_da.c > index 9b3d706d6168..0daaff9229b0 100644 > --- a/sys/cam/scsi/scsi_da.c > +++ b/sys/cam/scsi/scsi_da.c > @@ -4208,6 +4208,9 @@ da_delete_trim(struct cam_periph *periph, union ccb *ccb, struct bio *bp) > da_default_timeout * 1000); > ccb->ccb_h.ccb_state = DA_CCB_DELETE; > ccb->ccb_h.flags |= CAM_UNLOCKED; > + softc->trim_count++; > + softc->trim_ranges += ranges; > + softc->trim_lbas += block_count; > cam_iosched_submit_trim(softc->cam_iosched); > } > > @@ -4268,6 +4271,9 @@ da_delete_ws(struct cam_periph *periph, union ccb *ccb, struct bio *bp) > da_default_timeout * 1000); > ccb->ccb_h.ccb_state = DA_CCB_DELETE; > ccb->ccb_h.flags |= CAM_UNLOCKED; > + softc->trim_count++; > + softc->trim_ranges++; > + softc->trim_lbas += count; > cam_iosched_submit_trim(softc->cam_iosched); > } > > > > > ------=_Part_10420_1216642803.1714749653117 Content-Type: text/html; charset=us-ascii Content-Transfer-Encoding: 7bit Are you sure you used the right PR?

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=277637
"[NEW PORT] security/enc: Modern and friendly CLI alternative to GnuPG"


Regards,
Ronald.


 

Van: Warner Losh <imp@FreeBSD.org>
Datum: vrijdag, 3 mei 2024 16:47
Aan: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Onderwerp: git: 12117d0e9314 - main - da: Update trim stats for WRITE SAME and ATA TRIM

The branch main has been updated by imp:

URL: https://cgit.FreeBSD.org/src/commit/?id=12117d0e9314d1706508386c1c49ace2de578b31

commit 12117d0e9314d1706508386c1c49ace2de578b31
Author:     Matthew Grooms <mgrooms@shrew.net>
AuthorDate: 2024-05-03 14:41:05 +0000
Commit:     Warner Losh <imp@FreeBSD.org>
CommitDate: 2024-05-03 14:46:59 +0000

    da: Update trim stats for WRITE SAME and ATA TRIM
    
    The scsi UNMAP path updated trim stats in the da sysctl, but the ATA
    TRIM passthru and WRITE SAME paths did not. Add code so they do.
    
    PR: 277637
    Reviewed by: imp (tweaked WS path to update ranges)
---
 sys/cam/scsi/scsi_da.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/sys/cam/scsi/scsi_da.c b/sys/cam/scsi/scsi_da.c
index 9b3d706d6168..0daaff9229b0 100644
--- a/sys/cam/scsi/scsi_da.c
+++ b/sys/cam/scsi/scsi_da.c
@@ -4208,6 +4208,9 @@ da_delete_trim(struct cam_periph *periph, union ccb *ccb, struct bio *bp)
              da_default_timeout * 1000);
    ccb->ccb_h.ccb_state = DA_CCB_DELETE;
    ccb->ccb_h.flags |= CAM_UNLOCKED;
+   softc->trim_count++;
+   softc->trim_ranges += ranges;
+   softc->trim_lbas += block_count;
    cam_iosched_submit_trim(softc->cam_iosched);
 }
 
@@ -4268,6 +4271,9 @@ da_delete_ws(struct cam_periph *periph, union ccb *ccb, struct bio *bp)
            da_default_timeout * 1000);
    ccb->ccb_h.ccb_state = DA_CCB_DELETE;
    ccb->ccb_h.flags |= CAM_UNLOCKED;
+   softc->trim_count++;
+   softc->trim_ranges++;
+   softc->trim_lbas += count;
    cam_iosched_submit_trim(softc->cam_iosched);
 }
 
 


  ------=_Part_10420_1216642803.1714749653117--