cregit-Linux how code gets into the kernel

Release 4.12 include/net/hwbm.h

Directory: include/net
#ifndef _HWBM_H

#define _HWBM_H


struct hwbm_pool {
	/* Capacity of the pool */
	
int size;
	/* Size of the buffers managed */
	
int frag_size;
	/* Number of buffers currently used by this pool */
	
int buf_num;
	/* constructor called during alocation */
	
int (*construct)(struct hwbm_pool *bm_pool, void *buf);
	/* protect acces to the buffer counter*/
	
spinlock_t lock;
	/* private data */
	
void *priv;
};
#ifdef CONFIG_HWBM
void hwbm_buf_free(struct hwbm_pool *bm_pool, void *buf);
int hwbm_pool_refill(struct hwbm_pool *bm_pool, gfp_t gfp);
int hwbm_pool_add(struct hwbm_pool *bm_pool, unsigned int buf_num, gfp_t gfp);
#else

void hwbm_buf_free(struct hwbm_pool *bm_pool, void *buf) {}

Contributors

PersonTokensPropCommitsCommitProp
Gregory CLEMENT13100.00%1100.00%
Total13100.00%1100.00%


int hwbm_pool_refill(struct hwbm_pool *bm_pool, gfp_t gfp) { return 0; }

Contributors

PersonTokensPropCommitsCommitProp
Gregory CLEMENT16100.00%1100.00%
Total16100.00%1100.00%


int hwbm_pool_add(struct hwbm_pool *bm_pool, unsigned int buf_num, gfp_t gfp) { return 0; }

Contributors

PersonTokensPropCommitsCommitProp
Gregory CLEMENT20100.00%1100.00%
Total20100.00%1100.00%

#endif /* CONFIG_HWBM */ #endif /* _HWBM_H */

Overall Contributors

PersonTokensPropCommitsCommitProp
Gregory CLEMENT150100.00%1100.00%
Total150100.00%1100.00%
Directory: include/net
Information contained on this website is for historical information purposes only and does not indicate or represent copyright ownership.
Created with cregit.