From patchwork Wed Apr 17 21:44:36 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bart Van Assche X-Patchwork-Id: 10906271 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id EAC0C1390 for ; Wed, 17 Apr 2019 21:45:45 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D679628A93 for ; Wed, 17 Apr 2019 21:45:45 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id CB25428BA9; Wed, 17 Apr 2019 21:45:45 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 6EFEE28A93 for ; Wed, 17 Apr 2019 21:45:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387946AbfDQVpa (ORCPT ); Wed, 17 Apr 2019 17:45:30 -0400 Received: from mail-pf1-f196.google.com ([209.85.210.196]:37834 "EHLO mail-pf1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387539AbfDQVp1 (ORCPT ); Wed, 17 Apr 2019 17:45:27 -0400 Received: by mail-pf1-f196.google.com with SMTP id 8so84007pfr.4 for ; Wed, 17 Apr 2019 14:45:27 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=mkb4hVWFHkNHGFxpBTHQY5E3+UAPRXX87pgy6wMcgX0=; b=Gxb7/lN6i9InPdO2+YJ8mY/bCxYVFtCAQvoIB2xkInmwSboYCo007KL/Ft9SkBmnNj vMnaA7fq5JrTmrd/HWED5IvECbTbn1isBWH/+sFokBa1bgvgYEVntTuhS7FFA1vAJpsk AClwfzCqvDqVfgG/YATpkF362zYm2EsXXVgdIXkWQ7ipjcYQVeNCBV8lId+gRMwvaJ6z jkKzmfUFLKtBeS94BHKRg6YCwnd94oPF3QiUO+LDh49QBlpNXIF7563miPOpzXEpt51P 1TfoG17N9B0rvsdxo2EKZs102ZniKwgjUHKYAS6J1xCSZ7pV5fJ9fa6grkfxjiboGPum 9/ig== X-Gm-Message-State: APjAAAXphHvKX1F0bJwePtC3ConQQAUJOAfaLX9wDkVN5tCDWnmlBvoa NfyWSYEZbcFi233wUR6g2nU= X-Google-Smtp-Source: APXvYqxLXeJplyC7JE0kYh+JsTIhFcKkU+4nUrTggVZQCUnL80qekKecor7hQX7ntu7ysilPgDEtBg== X-Received: by 2002:a63:c302:: with SMTP id c2mr86166058pgd.235.1555537526732; Wed, 17 Apr 2019 14:45:26 -0700 (PDT) Received: from desktop-bart.svl.corp.google.com ([2620:15c:2cd:203:5cdc:422c:7b28:ebb5]) by smtp.gmail.com with ESMTPSA id d68sm219314pfg.16.2019.04.17.14.45.25 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 17 Apr 2019 14:45:26 -0700 (PDT) From: Bart Van Assche To: "Martin K . Petersen" , "James E . J . Bottomley" Cc: linux-scsi@vger.kernel.org, Christoph Hellwig , Bart Van Assche , Himanshu Madhani , Giridhar Malavali Subject: [PATCH 27/34] qla2xxx: Pass little-endian values to the firmware Date: Wed, 17 Apr 2019 14:44:36 -0700 Message-Id: <20190417214443.243152-28-bvanassche@acm.org> X-Mailer: git-send-email 2.20.GIT In-Reply-To: <20190417214443.243152-1-bvanassche@acm.org> References: <20190417214443.243152-1-bvanassche@acm.org> MIME-Version: 1.0 Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Pass dsd_list_len in little endian format to the firmware instead of in CPU endian format. Cc: Himanshu Madhani Cc: Giridhar Malavali Signed-off-by: Bart Van Assche --- drivers/scsi/qla2xxx/qla_iocb.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/scsi/qla2xxx/qla_iocb.c b/drivers/scsi/qla2xxx/qla_iocb.c index 60f6685cb342..19eb18be2316 100644 --- a/drivers/scsi/qla2xxx/qla_iocb.c +++ b/drivers/scsi/qla2xxx/qla_iocb.c @@ -973,7 +973,7 @@ qla24xx_walk_and_build_sglist_no_difb(struct qla_hw_data *ha, srb_t *sp, /* add new list to cmd iocb or last list */ *cur_dsd++ = cpu_to_le32(LSD(dsd_ptr->dsd_list_dma)); *cur_dsd++ = cpu_to_le32(MSD(dsd_ptr->dsd_list_dma)); - *cur_dsd++ = dsd_list_len; + *cur_dsd++ = cpu_to_le32(dsd_list_len); cur_dsd = (uint32_t *)next_dsd; } *cur_dsd++ = cpu_to_le32(LSD(sle_dma)); @@ -1072,7 +1072,7 @@ qla24xx_walk_and_build_sglist(struct qla_hw_data *ha, srb_t *sp, uint32_t *dsd, /* add new list to cmd iocb or last list */ *cur_dsd++ = cpu_to_le32(LSD(dsd_ptr->dsd_list_dma)); *cur_dsd++ = cpu_to_le32(MSD(dsd_ptr->dsd_list_dma)); - *cur_dsd++ = dsd_list_len; + *cur_dsd++ = cpu_to_le32(dsd_list_len); cur_dsd = (uint32_t *)next_dsd; } sle_dma = sg_dma_address(sg); @@ -1317,7 +1317,7 @@ qla24xx_walk_and_build_prot_sglist(struct qla_hw_data *ha, srb_t *sp, cpu_to_le32(LSD(dsd_ptr->dsd_list_dma)); *cur_dsd++ = cpu_to_le32(MSD(dsd_ptr->dsd_list_dma)); - *cur_dsd++ = dsd_list_len; + *cur_dsd++ = cpu_to_le32(dsd_list_len); cur_dsd = dsd_ptr->dsd_addr; } *cur_dsd++ = cpu_to_le32(LSD(dif_dsd->dsd_list_dma)); @@ -1378,7 +1378,7 @@ qla24xx_walk_and_build_prot_sglist(struct qla_hw_data *ha, srb_t *sp, cpu_to_le32(LSD(dsd_ptr->dsd_list_dma)); *cur_dsd++ = cpu_to_le32(MSD(dsd_ptr->dsd_list_dma)); - *cur_dsd++ = dsd_list_len; + *cur_dsd++ = cpu_to_le32(dsd_list_len); cur_dsd = dsd_ptr->dsd_addr; } sle_dma = sg_dma_address(sg);