From owner-svn-src-stable@freebsd.org Sun Jun 17 17:32:33 2018 Return-Path: Delivered-To: svn-src-stable@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 478621003492; Sun, 17 Jun 2018 17:32:33 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id EE9DB77062; Sun, 17 Jun 2018 17:32:32 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id CFCB118747; Sun, 17 Jun 2018 17:32:32 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id w5HHWWnE027421; Sun, 17 Jun 2018 17:32:32 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id w5HHWW7i027419; Sun, 17 Jun 2018 17:32:32 GMT (envelope-from dim@FreeBSD.org) Message-Id: <201806171732.w5HHWW7i027419@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Sun, 17 Jun 2018 17:32:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r335291 - stable/11/sys/dev/ocs_fc X-SVN-Group: stable-11 X-SVN-Commit-Author: dim X-SVN-Commit-Paths: stable/11/sys/dev/ocs_fc X-SVN-Commit-Revision: 335291 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 17 Jun 2018 17:32:33 -0000 Author: dim Date: Sun Jun 17 17:32:32 2018 New Revision: 335291 URL: https://svnweb.freebsd.org/changeset/base/335291 Log: MFC r334945: Fix build of ocs_fs with base gcc on i386 Add a few intermediate casts to uintptr_t to suppress "cast to pointer from integer of different size" warnings from gcc. Also remove a few incorrect casts. Reviewed by: ram Differential Revision: https://reviews.freebsd.org/D15747 Modified: stable/11/sys/dev/ocs_fc/ocs_ioctl.c stable/11/sys/dev/ocs_fc/ocs_sport.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/dev/ocs_fc/ocs_ioctl.c ============================================================================== --- stable/11/sys/dev/ocs_fc/ocs_ioctl.c Sun Jun 17 17:31:16 2018 (r335290) +++ stable/11/sys/dev/ocs_fc/ocs_ioctl.c Sun Jun 17 17:32:32 2018 (r335291) @@ -140,7 +140,7 @@ ocs_process_sli_config (ocs_t *ocs, ocs_ioctl_elxu_mbo wrobj->host_buffer_descriptor[0].u.data.buffer_address_high = ocs_addr32_hi(dma->phys); /* copy the data into the DMA buffer */ - copyin((void *)mcmd->in_addr, dma->virt, mcmd->in_bytes); + copyin((void *)(uintptr_t)mcmd->in_addr, dma->virt, mcmd->in_bytes); } break; case SLI4_OPC_COMMON_DELETE_OBJECT: @@ -169,8 +169,8 @@ ocs_process_sli_config (ocs_t *ocs, ocs_ioctl_elxu_mbo break; default: device_printf(ocs->dev, "%s: in=%p (%lld) out=%p (%lld)\n", __func__, - (void *)mcmd->in_addr, (unsigned long long)mcmd->in_bytes, - (void *)mcmd->out_addr, (unsigned long long)mcmd->out_bytes); + (void *)(uintptr_t)mcmd->in_addr, (unsigned long long)mcmd->in_bytes, + (void *)(uintptr_t)mcmd->out_addr, (unsigned long long)mcmd->out_bytes); device_printf(ocs->dev, "%s: unknown (opc=%#x)\n", __func__, req->opcode); hexdump(mcmd, mcmd->size, NULL, 0); @@ -184,7 +184,7 @@ ocs_process_sli_config (ocs_t *ocs, ocs_ioctl_elxu_mbo return ENXIO; } - copyin((void *)mcmd->in_addr, dma->virt, mcmd->in_bytes); + copyin((void *)(uintptr_t)mcmd->in_addr, dma->virt, mcmd->in_bytes); sli_config->payload.mem.address_low = ocs_addr32_lo(dma->phys); sli_config->payload.mem.address_high = ocs_addr32_hi(dma->phys); @@ -250,7 +250,7 @@ ocs_process_mbx_ioctl(ocs_t *ocs, ocs_ioctl_elxu_mbox_ if( SLI4_MBOX_COMMAND_SLI_CONFIG == ((sli4_mbox_command_header_t *)mcmd->payload)->command && mcmd->out_bytes && dma.virt) { - copyout(dma.virt, (void *)mcmd->out_addr, mcmd->out_bytes); + copyout(dma.virt, (void *)(uintptr_t)mcmd->out_addr, mcmd->out_bytes); } no_support: Modified: stable/11/sys/dev/ocs_fc/ocs_sport.c ============================================================================== --- stable/11/sys/dev/ocs_fc/ocs_sport.c Sun Jun 17 17:31:16 2018 (r335290) +++ stable/11/sys/dev/ocs_fc/ocs_sport.c Sun Jun 17 17:32:32 2018 (r335291) @@ -781,7 +781,7 @@ __ocs_sport_attached(ocs_sm_ctx_t *ctx, ocs_sm_event_t case OCS_EVT_ENTER: { ocs_node_t *node; - ocs_log_debug(ocs, "[%s] SPORT attached WWPN %016llx WWNN %016llx \n", (unsigned long long)sport->display_name, + ocs_log_debug(ocs, "[%s] SPORT attached WWPN %016llx WWNN %016llx \n", sport->display_name, sport->wwpn, sport->wwnn); ocs_sport_lock(sport); ocs_list_foreach(&sport->node_list, node) { @@ -805,7 +805,7 @@ __ocs_sport_attached(ocs_sm_ctx_t *ctx, ocs_sm_event_t } case OCS_EVT_EXIT: - ocs_log_debug(ocs, "[%s] SPORT deattached WWPN %016llx WWNN %016llx \n", (unsigned long long)sport->display_name, + ocs_log_debug(ocs, "[%s] SPORT deattached WWPN %016llx WWNN %016llx \n", sport->display_name, sport->wwpn, sport->wwnn); if (sport->enable_ini) { ocs_scsi_ini_del_sport(sport);