Browse Source

qcacld-3.0: Use published method to reset vdev ospriv

Currently hdd_release_and_destroy_vdev() resets the vdev's ospriv data
pointer by directly dereferencing the vdev object. This is not the
correct object-oriented approach. Instead of dereferencing the object,
invoke the wlan_vdev_reset_ospriv() method that exists for this
purpose.

Change-Id: I68a504b022933a47276d5c76c079472e8d3a6402
CRs-Fixed: 2024020
Jeff Johnson 8 years ago
parent
commit
39d8d33efc
1 changed files with 1 additions and 1 deletions
  1. 1 1
      core/hdd/src/wlan_hdd_object_manager.c

+ 1 - 1
core/hdd/src/wlan_hdd_object_manager.c

@@ -197,7 +197,7 @@ int hdd_objmgr_destroy_vdev(hdd_adapter_t *adapter)
 		return -EINVAL;
 
 	osif_priv = wlan_vdev_get_ospriv(vdev);
-	vdev->vdev_nif.osdev = NULL;
+	wlan_vdev_reset_ospriv(vdev);
 	qdf_mem_free(osif_priv);
 
 	if (hdd_objmgr_remove_peer_object(vdev,