/* * lib80211.h -- common bits for IEEE802.11 wireless drivers * * Copyright (c) 2008, John W. Linville * * Some bits copied from old ieee80211 component, w/ original copyright * notices below: * * Original code based on Host AP (software wireless LAN access point) driver * for Intersil Prism2/2.5/3. * * Copyright (c) 2001-2002, SSH Communications Security Corp and Jouni Malinen * * Copyright (c) 2002-2003, Jouni Malinen * * Adaption to a generic IEEE 802.11 stack by James Ketrenos * * * Copyright (c) 2004, Intel Corporation * */ #ifndef LIB80211_H #define LIB80211_H #include #include #include #include #include #include #include #include #define NUM_WEP_KEYS 4 enum { IEEE80211_CRYPTO_TKIP_COUNTERMEASURES = (1 << 0), }; struct module; struct lib80211_crypto_ops { const char *name; struct list_head list; /* init new crypto context (e.g., allocate private data space, * select IV, etc.); returns NULL on failure or pointer to allocated * private data on success */ void *(*init) (int keyidx); /* deinitialize crypto context and free allocated private data */ void (*deinit) (void *priv); /* encrypt/decrypt return < 0 on error or >= 0 on success. The return * value from decrypt_mpdu is passed as the keyidx value for * decrypt_msdu. skb must have enough head and tail room for the * encryption; if not, error will be returned; these functions are * called for all MPDUs (i.e., fragments). */ int (*encrypt_mpdu) (struct sk_buff * skb, int hdr_len, void *priv); int (*decrypt_mpdu) (struct sk_buff * skb, int hdr_len, void *priv); /* These functions are called for full MSDUs, i.e. full frames. * These can be NULL if full MSDU operations are not needed. */ int (*encrypt_msdu) (struct sk_buff * skb, int hdr_len, void *priv); int (*decrypt_msdu) (struct sk_buff * skb, int keyidx, int hdr_len, void *priv); int (*set_key) (void *key, int len, u8 * seq, void *priv); int (*get_key) (void *key, int len, u8 * seq, void *priv); /* procfs handler for printing out key information and possible * statistics */ void (*print_stats) (struct seq_file *m, void *priv); /* Crypto specific flag get/set for configuration settings */ unsigned long (*get_flags) (void *priv); unsigned long (*set_flags) (unsigned long flags, void *priv); /* maximum number of bytes added by encryption; encrypt buf is * allocated with extra_prefix_len bytes, copy of in_buf, and * extra_postfix_len; encrypt need not use all this space, but * the result must start at the beginning of the buffer and correct * length must be returned */ int extra_mpdu_prefix_len, extra_mpdu_postfix_len; int extra_msdu_prefix_len, extra_msdu_postfix_len; struct module *owner; }; struct lib80211_crypt_data { struct list_head list; /* delayed deletion list */ struct lib80211_crypto_ops *ops; void *priv; atomic_t refcnt; }; struct lib80211_crypt_info { char *name; /* Most clients will already have a lock, so just point to that. */ spinlock_t *lock; struct lib80211_crypt_data *crypt[NUM_WEP_KEYS]; int tx_keyidx; /* default TX key index (crypt[tx_keyidx]) */ struct list_head crypt_deinit_list; struct timer_list crypt_deinit_timer; int crypt_quiesced; }; int lib80211_crypt_info_init(struct lib80211_crypt_info *info, char *name, spinlock_t *lock); void lib80211_crypt_info_free(struct lib80211_crypt_info *info); int lib80211_register_crypto_ops(struct lib80211_crypto_ops *ops); int lib80211_unregister_crypto_ops(struct lib80211_crypto_ops *ops); struct lib80211_crypto_ops *lib80211_get_crypto_ops(const char *name); void lib80211_crypt_delayed_deinit(struct lib80211_crypt_info *info, struct lib80211_crypt_data **crypt); #endif /* LIB80211_H */ 22e21e7619bb8751aa1cd32a9b671b1baaf3d18'>plain -rw-r--r--drmP.h25776logplain -rw-r--r--drm_agpsupport.h3867logplain -rw-r--r--drm_atomic.h14443logplain -rw-r--r--drm_atomic_helper.h10607logplain -rw-r--r--drm_auth.h2260logplain -rw-r--r--drm_blend.h2700logplain -rw-r--r--drm_bridge.h7977logplain -rw-r--r--drm_cache.h1763logplain -rw-r--r--drm_color_mgmt.h2166logplain -rw-r--r--drm_connector.h28975logplain -rw-r--r--drm_crtc.h28999logplain -rw-r--r--drm_crtc_helper.h3301logplain -rw-r--r--drm_debugfs_crc.h2670logplain -rw-r--r--drm_displayid.h2850logplain -rw-r--r--drm_dp_dual_mode_helper.h4532logplain -rw-r--r--drm_dp_helper.h30638logplain -rw-r--r--drm_dp_mst_helper.h16260logplain -rw-r--r--drm_drv.h14861logplain -rw-r--r--drm_edid.h14335logplain -rw-r--r--drm_encoder.h8160logplain -rw-r--r--drm_encoder_slave.h6583logplain -rw-r--r--drm_fb_cma_helper.h1929logplain -rw-r--r--drm_fb_helper.h15125logplain -rw-r--r--drm_fixed.h4825logplain -rw-r--r--drm_flip_work.h3071logplain -rw-r--r--drm_fourcc.h2748logplain -rw-r--r--drm_framebuffer.h9623logplain -rw-r--r--drm_gem.h8052logplain -rw-r--r--drm_gem_cma_helper.h2286logplain -rw-r--r--drm_global.h2011logplain -rw-r--r--drm_hashtab.h3139logplain -rw-r--r--drm_irq.h6323logplain -rw-r--r--drm_legacy.h6933logplain -rw-r--r--drm_mem_util.h2468logplain -rw-r--r--drm_mipi_dsi.h10327logplain -rw-r--r--drm_mm.h11462logplain -rw-r--r--drm_mode_config.h23728logplain -rw-r--r--drm_mode_object.h4911logplain -rw-r--r--drm_modes.h17078logplain -rw-r--r--drm_modeset_helper.h1576logplain -rw-r--r--drm_modeset_helper_vtables.h41180logplain -rw-r--r--drm_modeset_lock.h4241logplain -rw-r--r--drm_of.h2034logplain -rw-r--r--drm_os_linux.h2230logplain -rw-r--r--drm_panel.h7079logplain -rw-r--r--drm_pciids.h68035logplain -rw-r--r--drm_plane.h19435logplain -rw-r--r--drm_plane_helper.h3186logplain -rw-r--r--drm_print.h3232logplain -rw-r--r--drm_property.h11460logplain -rw-r--r--drm_rect.h5103logplain -rw-r--r--drm_simple_kms_helper.h4090logplain -rw-r--r--drm_sysfs.h300logplain -rw-r--r--drm_vma_manager.h7840logplain -rw-r--r--gma_drm.h1033logplain d---------i2c109logplain