From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751945AbeDJBK0 (ORCPT ); Mon, 9 Apr 2018 21:10:26 -0400 Received: from kvm5.telegraphics.com.au ([98.124.60.144]:41492 "EHLO kvm5.telegraphics.com.au" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751671AbeDJBKZ (ORCPT ); Mon, 9 Apr 2018 21:10:25 -0400 Date: Tue, 10 Apr 2018 11:10:10 +1000 (AEST) From: Finn Thain To: Geert Uytterhoeven cc: Laurent Vivier , Jens Axboe , linux-m68k , Linux Kernel Mailing List Subject: Re: [PATCH 06/12] block/swim: Fix array bounds check In-Reply-To: Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 9 Apr 2018, Geert Uytterhoeven wrote: > Looks like amiflop.c:find_floppy() needs a check, too? > AFAICS there is no array index bug in floppy_find() in amiflop.c. The 'unit' array's size is FD_MAX_UNITS which is defined as 4 in include/linux/amifd.h, and the array index is drive = *part & 3. --