lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20170925125107.GC8130@lst.de>
Date:   Mon, 25 Sep 2017 14:51:07 +0200
From:   Christoph Hellwig <hch@....de>
To:     Huacai Chen <chenhc@...ote.com>
Cc:     Christoph Hellwig <hch@....de>,
        Marek Szyprowski <m.szyprowski@...sung.com>,
        Robin Murphy <robin.murphy@....com>,
        Andrew Morton <akpm@...ux-foundation.org>,
        Fuxin Zhang <zhangfx@...ote.com>, linux-kernel@...r.kernel.org,
        Ralf Baechle <ralf@...ux-mips.org>,
        James Hogan <james.hogan@...tec.com>,
        linux-mips@...ux-mips.org,
        "James E . J . Bottomley" <jejb@...ux.vnet.ibm.com>,
        "Martin K . Petersen" <martin.petersen@...cle.com>,
        linux-scsi@...r.kernel.org, Roland Dreier <rolandd@...co.com>,
        Pawel Osciak <pawel@...iak.com>,
        Kyungmin Park <kyungmin.park@...sung.com>,
        Michael Chan <michael.chan@...adcom.com>,
        Benjamin Herrenschmidt <benh@...nel.crashing.org>,
        Ivan Mikhaylov <ivan@...ibm.com>,
        Tariq Toukan <tariqt@...lanox.com>,
        Andy Gross <agross@...eaurora.org>,
        "Mark A . Greer" <mgreer@...sta.com>,
        Robert Baldyga <r.baldyga@...sung.com>, stable@...r.kernel.org
Subject: Re: [PATCH V7 1/2] dma-mapping: Rework dma_get_cache_alignment()

> index aba7138..e2c5d9e 100644
> --- a/arch/mips/include/asm/dma-mapping.h
> +++ b/arch/mips/include/asm/dma-mapping.h
> @@ -39,4 +39,6 @@ static inline void arch_setup_dma_ops(struct device *dev, u64 dma_base,
>  #endif
>  }
>  
> +int mips_get_cache_alignment(struct device *dev);

All the other mips generic dma helpers are prefixed mips_dma_*
so it might make sense to follow that.

Also please don't add arch-local helpers to asm/dma-mapping.h - this
is a header used by linux/dma-mapping.h and should not contain
implementation details if avoidable.

> +					   dma_get_cache_alignment(NULL)) / mdev->limits.mtt_seg_size;

As said before - please don't pass NULL to this function but the proper
device, which would be &mdev->pdev->dev in this case for example.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ