From: Dietmar Maurer <dietmar@proxmox.com>
To: Proxmox Backup Server development discussion
<pbs-devel@lists.proxmox.com>,
Wolfgang Bumiller <w.bumiller@proxmox.com>,
Thomas Lamprecht <t.lamprecht@proxmox.com>,
Dominik Csapak <d.csapak@proxmox.com>
Subject: Re: [pbs-devel] [PATCH proxmox-backup v2 03/14] tape/drive: clippy fixes
Date: Mon, 19 Apr 2021 17:46:34 +0200 (CEST) [thread overview]
Message-ID: <136047145.4110.1618847194828@webmail.proxmox.com> (raw)
> > But it is though, they are from the SCSI reference
> > "Mode Parameter Header for Mode Select"
> >
> > +--+--+--+--+--+--+--+--+
> > |WP| B.MODE | SPEED |
> > +--+--+--+--+--+--+--+--+
> >
> > (write protect, buffer mode, speed)
> >
> > so this is the wrong solution, the right one would be:
> > * keep as is
> > * introduce constant like BUFFER_MODE_MASK 0b01110000 and use it negated here
>
> ^ So let's do this then.
>
> I do think this particular lint is the least useful one TBH. When working on embedded
> riscv code I was pretty much constantly fighting with it...
>
> And maybe when the base is done we should also go through all the data structures and
> add doc comments referencing the corresponding scsi documentation to make it easier
> to navigate?
Instead, I would search for a real solution, some kind of bitfield:
https://immunant.com/blog/2020/01/bitfields/
Not sure whats best ...
next reply other threads:[~2021-04-19 15:47 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-19 15:46 Dietmar Maurer [this message]
-- strict thread matches above, loose matches on Subject: below --
2021-04-19 12:09 Wolfgang Bumiller
2021-04-19 9:35 Dietmar Maurer
2021-04-19 8:38 Wolfgang Bumiller
2021-04-19 9:40 ` Thomas Lamprecht
2021-04-16 10:28 [pbs-devel] [PATCH proxmox-backup v2 00/14] various " Dominik Csapak
2021-04-16 10:28 ` [pbs-devel] [PATCH proxmox-backup v2 03/14] tape/drive: " Dominik Csapak
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=136047145.4110.1618847194828@webmail.proxmox.com \
--to=dietmar@proxmox.com \
--cc=d.csapak@proxmox.com \
--cc=pbs-devel@lists.proxmox.com \
--cc=t.lamprecht@proxmox.com \
--cc=w.bumiller@proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox