rtlwifi: Initialize rate_init member of struct rate_control_ops
authorCatalin Iacob <iacobcatalin@gmail.com>
Mon, 11 Feb 2013 21:18:05 +0000 (22:18 +0100)
committerJohn W. Linville <linville@tuxdriver.com>
Tue, 12 Feb 2013 16:09:04 +0000 (11:09 -0500)
commitc88d0dc1cc0182358ce1ae6f457dace34539eb12
tree4905ccdddbb00683566d9d9c603c27695cbd601c
parent4fe0c75eedb15af13859ef123db17fefed5af7ae
rtlwifi: Initialize rate_init member of struct rate_control_ops

This partially reverts commit 44ba973699b831414c3f8eef68ee5a7fe1208a05.

rate_control_rate_init assumes the rate_init member of
struct rate_control_ops is not NULL therefore not initializing it leads to
an oops as soon the driver succesfully associates to an AP.

The removal of rate_update from 44ba973699b831414c3f8eef68ee5a7fe1208a05
is ok because rate_update is checked for NULL before being
called.

Signed-off-by: Catalin Iacob <iacobcatalin@gmail.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/rtlwifi/rc.c