-
Notifications
You must be signed in to change notification settings - Fork 223
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
LibVirt: Initial support for virtio-scsi virtual drives (read: ssd trim) #1467
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As a follow-up for our previous IRC chat, thanks again for your contributions!
As discussed, this PR doesn't exactly follow the general contributing workflow as there was no issue to discuss/design changes first. To avoid being overly redundant, I'm not going to mention this on the rest of the PR reviews, but I'll provide a summary of our chat.
I think we agree on the overall goal here, so let's see how to get it on board.
- Ideally, there could be a related issue open about the exact use case, which this PR could close then.
- If this PR mixes a new feature with a bugfix, it would be preferable to have two commits for the two logical changes.
- As the CI failure indicates, the code requires to be reformatted with latest perltidy.
- As discussed, t/issue/948.t: Fixing whitespace detection in test #1472 could probably be folded into this PR as a related test change (perhaps it's a prerequisite even?).
527247d
to
9ccb484
Compare
+1
Done.
I reformatted the code with perltidy-20210111 and forced pushed the branch.
Done. |
Erm, I think what confuses me is that I see only one commit, but the commit message talks about two changes, and there are no tests to establish further context. I find it hard to guess which part of the diff is intended to solve which part of story. Do I understand it correctly, that the commit addresses two separate things (a new feature which got implemented, and a bug which got fixed)?
Context: Test::Perl::Critic::Progressive ensures that the amount of perlcritic violations in the codebase are not growing. It works by saving a reference state on first run, and then comparing against that state on subsequent runs (see description). It's failing in CI, because there are 4 new violations compared to master. I would do something like this to reproduce locally:
Nitpick, optional to fix: I would find the commit messages clear enough even without their prefixes (since the diff itself already communicates which file or subsystem is being modified). It's fine for now, but if we decide to split the commit, this can be easily addressed. |
I think I started to get it:
@alip: could you confirm if I understand it correctly now? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@alip: I believe I could understand the changes much better after a closer look at the libvirt XML definitions.
If my understanding is complete and correct now, I'd say let's do this:
- if possible, let's split the combined commit into:
- one that adds support to
driver_cache
and `driver_discard - another one that deals with the rest (SCSI bits)
- one that adds support to
- fix Test::Perl::Critic::Progressive complaints (I've left some line comments for that)
- see if there's a better default for SCSI controller model
A related test is already fixed as part of the PR, and adding a comprehensive test coverage would be out of scope. So I believe we could merge this as soon as we get to a passing state after the above list.
9ccb484
to
8d52f8b
Compare
Updated taking into account the requested changes. |
Thank you for following up, @alip! This looks good, but I need some time to get back into context before a full review. Stay tuned! |
@alip: thanks for the patience here! I think I'll rebase this on top of current default branch here to trigger a fresh round of CI tests. edit: oh, I thought I could rely on GitHub's feature to push to a PR's original branch as maintainer, but that didn't work here. @alip, please rebase on top of current default branch. @einhverfr: it seems one of the commits on this PR was originally authored by you (and using your gmail address). Given my impression of the context, and the fact that the same commit content has already been published under the same license in the adjust/Rex fork, I think that's fine. Still, I wished to make you aware of the case, and I'd be grateful for an explicit consent from your side to know it's OK with you to have that contributed by @alip and be merged upstream. |
Totally ok with the merge. |
driver_cache
anddriver_discard
keys in storage disk config.The SCSI model defaults to
virtio-scsi
and may be overriden by thescsi_model
parameter.The second change is also a bug fix since without a SCSI controller
configuration a VM with a virtual disk attached to a SCSI bus won't
boot.
This PR is an attempt to fix #1473 by .
Checklist