# Re: \[PATCH\] mm: Decline to manipulate the refcount on a slab page

- From: Hannes Reinecke \<hare@suse.de\>
- Date: 2025-03-13 08:34:45 
- List: netdev
- Page: https://ratatoskr.run/netdev/2025/03/6536989
- Thread: https://ratatoskr.run/netdev/2025/03/6536907/t.md

```text
On 3/13/25 08:36, Christoph Hellwig wrote:
> On Thu, Mar 13, 2025 at 08:22:01AM +0100, Hannes Reinecke wrote:
>> On 3/12/25 06:48, Christoph Hellwig wrote:
>>> On Tue, Mar 11, 2025 at 04:59:53PM +0000, Matthew Wilcox wrote:
>>>> So I have two questions:
>>>>
>>>> Hannes:
>>>>    - Why does nvme need to turn the kvec into a bio rather than just
>>>>      send it directly?
>>>
>>> It doensn't need to and in fact does not.
>>>
>> Errm ... nvmf_connect_admin_queue()/nvmf_connect_io_queue() does ...
>
> No kvec there.  Just plain old passthrough commands like many others.

I might be misunderstood.

nvmf_connect_command_prep() returns a kmalloced buffer.
That is stored in a bvec in _nvme_submit_sync_cmd() via
blk_mq_rq_map_kern()->bio_map_kern().
And from that point on we are dealing with bvecs (iterators
and all), and losing the information that the page referenced
is a slab page.

The argument is that the network layer expected a kvec iterator
when slab pages are referred to, not a bvec iterator.

Cheers,

Hannes
-- 
Dr. Hannes Reinecke                  Kernel Storage Architect
hare@suse.de                                +49 911 74053 688
SUSE Software Solutions GmbH, Frankenstr. 146, 90461 Nürnberg
HRB 36809 (AG Nürnberg), GF: I. Totev, A. McDonald, W. Knoblich
```
