LOCAL / net: bcm4358: call vfs functions instead of direct file ops
authorPrzemyslaw Marczak <p.marczak@samsung.com>
Mon, 2 Nov 2015 14:16:27 +0000 (15:16 +0100)
committerSeung-Woo Kim <sw0312.kim@samsung.com>
Wed, 14 Dec 2016 04:48:21 +0000 (13:48 +0900)
commit6303c74be19f942cfac0d2554b612546a630730e
tree04945abcd875e3eaa2792a2cda3b2f02a00aa936
parentd16dc1c1bb7803045e3d5b4d397d0b38a44d6d2d
LOCAL / net: bcm4358: call vfs functions instead of direct file ops

After enable writing the card's MAC address to filesystem by:

commit: LOCAL / net: bcm4358: Enable the some configurations

in the driver's code for bcmdhd4358, filesystem access is required
to read/write some settings, especially the card's MAC address.

Instead of calling proper fs functions, a direct calls were used
to particular file operations methods.
Since read/write operations are deprecated, the present code without
null pointer checking, refers to null function pointers.
This causes kernel panic when runs wpa_supplicant application.

This commit moves the direct calls to proper function calls,
which fixes the panic issue.

Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
Cc: Jaehoon Chung <jh80.chung@samsung.com>
drivers/net/wireless/bcmdhd4358/dhd_custom_sec.c