All of lore.kernel.org
 help / color / mirror / Atom feed
From: Vasant Hegde <vasant.hegde@amd.com>
To: Joerg Roedel <joro@8bytes.org>
Cc: iommu@lists.linux.dev, robin.murphy@arm.com, will@kernel.org,
	suravee.suthikulpanit@amd.com,
	Matt Fagnani <matt.fagnani@bell.net>
Subject: Re: [PATCH 3/3] iommu/amd: Call BUG_ON in page fault hanlder path if domain is NULL
Date: Fri, 3 Feb 2023 22:22:05 +0530	[thread overview]
Message-ID: <2dec28fa-3de6-ed0f-6d9f-0aba12be5052@amd.com> (raw)
In-Reply-To: <Y9zsE800/NhF8unH@8bytes.org>

Joerg,


On 2/3/2023 4:42 PM, Joerg Roedel wrote:
> Hi Vasant
> 
> On Fri, Feb 03, 2023 at 04:10:33PM +0530, Vasant Hegde wrote:
>> Initially I was thinking of logging error message and return. But it will hit
>> device faults continuously.  Also we don't have nice way to recover from this
>> condition.
>>
>> So I thought crashing here with explicit BUG_ON is better. But I agree with
>> Robin's comment. We don't really get anything extra with BUG_ON. We should be
>> able to figureout crash reason based on NULL pointer dereference easily.
>>
>> Do you want me to just add explicit log here? Otherwise I am fine dropping this
>> patch (3/3). I think we still need first two patches from this series.
> 
> The best for now is to print a ratelimited error message and just return
> from the handler. The ratelimit ensures that no misbehaving device can
> flood the kernel log.

Sure. Let me fix it and send v2.

-Vasant


  reply	other threads:[~2023-02-03 16:52 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-13 13:59 [PATCH 1/3] iommu: Attach device group to old domain in error path Vasant Hegde
2023-01-13 13:59 ` [PATCH 2/3] iommu/amd: Skip attach device domain is same as new domain Vasant Hegde
2023-01-13 13:59 ` [PATCH 3/3] iommu/amd: Call BUG_ON in page fault hanlder path if domain is NULL Vasant Hegde
2023-01-13 16:15   ` Robin Murphy
2023-01-17  4:56     ` Vasant Hegde
2023-02-03  9:36   ` Joerg Roedel
2023-02-03 10:40     ` Vasant Hegde
2023-02-03 11:12       ` Joerg Roedel
2023-02-03 16:52         ` Vasant Hegde [this message]
2023-02-01  5:19 ` [PATCH 1/3] iommu: Attach device group to old domain in error path Vasant Hegde

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2dec28fa-3de6-ed0f-6d9f-0aba12be5052@amd.com \
    --to=vasant.hegde@amd.com \
    --cc=iommu@lists.linux.dev \
    --cc=joro@8bytes.org \
    --cc=matt.fagnani@bell.net \
    --cc=robin.murphy@arm.com \
    --cc=suravee.suthikulpanit@amd.com \
    --cc=will@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.