On Tuesday 18 September 2007 23:42:33 Michael Wu wrote: > From: Michael Wu <flamingice@xxxxxxxxxxxx> > > This makes adm8211 use the new filter configuration API in mac80211. > > Signed-off-by: Michael Wu <flamingice@xxxxxxxxxxxx> > --- > static int adm8211_add_interface(struct ieee80211_hw *dev, > struct ieee80211_if_init_conf *conf) > { > struct adm8211_priv *priv = dev->priv; > - /* NOTE: using IEEE80211_IF_TYPE_MGMT to indicate no mode selected */ > - if (priv->mode != IEEE80211_IF_TYPE_MGMT) > - return -1; > + if (priv->mode != IEEE80211_IF_TYPE_MNTR) > + return -EOPNOTSUPP; > > switch (conf->type) { > case IEEE80211_IF_TYPE_STA: > - case IEEE80211_IF_TYPE_MNTR: > priv->mode = conf->type; > break; > default: > return -EOPNOTSUPP; > } > > - priv->mac_addr = conf->mac_addr; > + ADM8211_IDLE(); > + > + ADM8211_CSR_WRITE(PAR0, *(u32 *)conf->mac_addr); > + ADM8211_CSR_WRITE(PAR1, *(u16 *)(conf->mac_addr + 4)); This is broken on BigEndian platforms. use cpu_to_leX(). You can also replace the handcoded endianness conversion in adm8211_set_bssid by cpu_to_leX(). > + adm8211_update_mode(dev); > + > + ADM8211_RESTORE(); > > return 0; > } -- Greetings Michael. - To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html