staging: kpc2000: remove unnecessary assertions in kpc_dma_transfer

In kpc_dma_transfer(), the assertion that priv is NULL and priv->ldev
is NULL, are never satisfied. The two callers of the function,
dereference the fields before the function is called. This patch
removes the two BUG_ON calls.

Signed-off-by: Aditya Pakki <pakki001@umn.edu>
Link: https://lore.kernel.org/r/20191219172118.17456-1-pakki001@umn.edu
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Aditya Pakki 2019-12-19 11:21:11 -06:00 коммит произвёл Greg Kroah-Hartman
Родитель 398d999f96
Коммит d7a336d67a
1 изменённых файлов: 0 добавлений и 2 удалений

Просмотреть файл

@ -49,9 +49,7 @@ static int kpc_dma_transfer(struct dev_private_data *priv,
u64 dma_addr;
u64 user_ctl;
BUG_ON(priv == NULL);
ldev = priv->ldev;
BUG_ON(ldev == NULL);
acd = kzalloc(sizeof(*acd), GFP_KERNEL);
if (!acd) {