*参照元 [#k69155b5]
#backlinks

*説明 [#p5e91584]
-パス: [[linux-4.4.1/include/linux/scatterlist.h]]

-FIXME: これは何?
--説明


**引数 [#ocad4c71]
-
-struct scatterlist *sg
--
--[[linux-4.4.1/scatterlist]]
-struct page *page
--
--[[linux-4.4.1/page]]


**返り値 [#n3da5daf]
-
--
-なし


**参考 [#f3fd2274]


*実装 [#s64e9c4c]
 /**
  * sg_assign_page - Assign a given page to an SG entry
  * @sg:             SG entry
  * @page:           The page
  *
  * Description:
  *   Assign page to sg entry. Also see sg_set_page(), the most commonly used
  *   variant.
  *
  **/
 static inline void sg_assign_page(struct scatterlist *sg, struct page *page)
 {
         unsigned long page_link = sg->page_link & 0x3;
 
         /*
          * In order for the low bit stealing approach to work, pages
          * must be aligned at a 32-bit boundary as a minimum.
          */
         BUG_ON((unsigned long) page & 0x03);
-
--[[linux-4.4.1/BUG_ON()]]

 #ifdef CONFIG_DEBUG_SG
-
--[[linux-4.4.1/CONFIG_DEBUG_SG]]

         BUG_ON(sg->sg_magic != SG_MAGIC);
         BUG_ON(sg_is_chain(sg));
-
--[[linux-4.4.1/sg_is_chain()]]

 #endif
         sg->page_link = page_link | (unsigned long) page;
 }


*コメント [#hc09f8ae]

トップ   編集 差分 履歴 添付 複製 名前変更 リロード   新規 一覧 検索 最終更新   ヘルプ   最終更新のRSS