[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 1/2] ns16550: reject IRQ above nr_irqs


  • To: Marek Marczykowski-Górecki <marmarek@xxxxxxxxxxxxxxxxxxxxxx>
  • From: Jan Beulich <jbeulich@xxxxxxxx>
  • Date: Thu, 10 Mar 2022 16:23:00 +0100
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=CsZrN3FxF+triV9bB5oQeY6blxKlOudJ1Z1gRuhUxuE=; b=h/vOsrUquc+IBUyaKr1TOGYPaeKgrobgALWJ0+1KGoL4dmHFKX1LHyQeKScA7swCngmRLhylKHfN+pPSO8NvEwt7JHIPCKd/1xbLRYK2DhUIGfQ8PF2WA+80yPO4suE754I8VvLTf374ApwIN4EZcNxM9ZIl76vEQ7sAVFyUWAfgNLpcQyT6zFDBNRL2uxzxog+25SCBdn92Sw2NojEysN+Dyx556Frgoa3sj8brCAu8i5bN8895L+AjH2zrsuGHXD8fF/6RXkj5AC+UE8NrJK1gNODAxTW1bljHvwi8VvD16geFh0alY5PwXrqSf26ncah+Uar83/6PIopSXB4tjA==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=YKUP5t/R3cy5BIbWWHjwifDQU4TBmDy+1W2HhoK/AY2mqTxgfiTClXAu+vOD9IJIwafLc3Q9AgoLOh6U8hQl+bBvpCISOPlS9o2iWJFhjAW8SU2BQ3cvCK29cIU5zkVosmffyI22VFkimtxyhQxr6h9oHwiXpZsvXI4s9igy6ovC+oYK0jq8gXuG+fgoDc3H+apCaOaEbmetboRNSUG6t1R59WwkIAML5qFn0W7q4y3VM64CrFaaY9BcuKwx/pJtkEV6Ua9TdvNIcSfLmTneYn6Hyjy33rVEActFk24vlRjVkb/ku+BN7Qn/lAYxkdift3IIWye1S19bmodSQiyoFg==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com;
  • Cc: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, George Dunlap <george.dunlap@xxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
  • Delivery-date: Thu, 10 Mar 2022 15:23:19 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On 10.03.2022 15:34, Marek Marczykowski-Górecki wrote:
> --- a/xen/drivers/char/ns16550.c
> +++ b/xen/drivers/char/ns16550.c
> @@ -1221,6 +1221,9 @@ pci_uart_config(struct ns16550 *uart, bool_t skip_amt, 
> unsigned int idx)
>                              pci_conf_read8(PCI_SBDF(0, b, d, f),
>                                             PCI_INTERRUPT_LINE) : 0;
>  
> +                if (uart->irq >= nr_irqs)
> +                    uart->irq = 0;

Don't you mean nr_irqs_gsi here? Also (nit) please add the missing blanks
immediately inside the parentheses.

Jan




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.