cfg80211: add helper to find an IE that matches a byte-array
authorLuca Coelho <luciano.coelho@intel.com>
Thu, 15 Sep 2016 15:15:09 +0000 (18:15 +0300)
committerJohannes Berg <johannes.berg@intel.com>
Fri, 16 Sep 2016 12:49:52 +0000 (14:49 +0200)
commitfbd05e4a6e82fd573d3aa79e284e424b8d78c149
treec07fd93b72d2cff80545cab21f5f2e5cfed26325
parentb59abfbed638037f3b51eeb73266892cd2df177f
cfg80211: add helper to find an IE that matches a byte-array

There are a few places where an IE that matches not only the EID, but
also other bytes inside the element, needs to be found.  To simplify
that and reduce the amount of similar code, implement a new helper
function to match the EID and an extra array of bytes.

Additionally, simplify cfg80211_find_vendor_ie() by using the new
match function.

Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
include/net/cfg80211.h
net/wireless/scan.c