Messages in this thread | | | Subject | Re: [PATCH net-next 5/9] page_pool: don't use driver-set flags field directly | From | Yunsheng Lin <> | Date | Wed, 2 Aug 2023 19:36:17 +0800 |
| |
On 2023/8/1 21:36, Alexander Lobakin wrote:
>> >> It just seems odd to me that dma_map and page_frag is duplicated as we >> seems to have the same info in the page_pool->p.flags. > > It's just because we copy the whole &page_pool_params passed by the > driver. It doesn't look good to me to define a new structure and copy > the values field-by-field just to avoid duplicating 3 bits :s > >> >> What about: >> In [PATCH net-next 4/9] page_pool: shrink &page_pool_params a tiny bit, >> 'flags' is bit-field'ed with 'dma_dir', what about changing 'dma_dir' >> to be bit-field'ed with 'dma_sync_act', so that page_pool->p.flags stays >> the same as before, and 'dma_map' & 'page_frag' do not seems be really >> needed as we have the same info in page_pool->p.flags? > > Not sure I follow :z ::dma_dir is also passed by the driver, so we can't > drop it from the params struct.
My bad, I missed that dma_dir is in the params struct.
| |