Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 68a4bcad authored by Jordan Crouse's avatar Jordan Crouse Committed by Hridaya Prajapati
Browse files

crypto: msm: Fix compile errors



Fix an out of order definition of MODULE_DEVICE_TABLE, add missing
brackets to fix a suspect indentation warning and mark an
implcit switch fall through.

Fixes: 377c69bf3e72 ("crypto: msm: Add QTI crypto drivers")
Change-Id: Ic0dedbada33fd2e5c692e5f0d64fd0e7b7afb5f1
Signed-off-by: default avatarJordan Crouse <jcrouse@codeaurora.org>
parent d0bee3c2
Loading
Loading
Loading
Loading
+7 −4
Original line number Diff line number Diff line
@@ -80,14 +80,14 @@ static dev_t qcedev_device_no;
static struct class *driver_class;
static struct device *class_dev;

MODULE_DEVICE_TABLE(of, qcedev_match);

static const struct of_device_id qcedev_match[] = {
	{	.compatible = "qcom,qcedev"},
	{	.compatible = "qcom,qcedev,context-bank"},
	{}
};

MODULE_DEVICE_TABLE(of, qcedev_match);

static uint32_t qcedev_get_block_size(enum qcedev_sha_alg_enum alg)
{
	switch (alg) {
@@ -1876,6 +1876,7 @@ static inline long qcedev_ioctl(struct file *file,
			err = -ENOTTY;
			goto exit_free_qcedev_areq;
		}
		/* Fall-through */
	case QCEDEV_IOCTL_SHA_UPDATE_REQ:
		{
		struct scatterlist sg_src;
@@ -1926,10 +1927,11 @@ static inline long qcedev_ioctl(struct file *file,
				handle->sha_ctxt.diglen);
		mutex_unlock(&hash_access_lock);
		if (copy_to_user((void __user *)arg, &qcedev_areq->sha_op_req,
					sizeof(struct qcedev_sha_op_req)))
					sizeof(struct qcedev_sha_op_req))) {
			err = -EFAULT;
			goto exit_free_qcedev_areq;
		}
		}
		break;

	case QCEDEV_IOCTL_SHA_FINAL_REQ:
@@ -2018,10 +2020,11 @@ static inline long qcedev_ioctl(struct file *file,
				handle->sha_ctxt.diglen);
		mutex_unlock(&hash_access_lock);
		if (copy_to_user((void __user *)arg, &qcedev_areq->sha_op_req,
					sizeof(struct qcedev_sha_op_req)))
					sizeof(struct qcedev_sha_op_req))) {
			err = -EFAULT;
			goto exit_free_qcedev_areq;
		}
		}
		break;

	case QCEDEV_IOCTL_MAP_BUF_REQ: