mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Prasad Sodagudi <psodagud@codeaurora.org>
To: aryabinin@virtuozzo.com, nicolas.iooss_linux@m4x.org,
	akpm@linux-foundation.org, mingo@kernel.org
Cc: linux-kernel@vger.kernel.org, psodagud@codeaurora.org
Subject: [PATCH] UBSAN: Add __ubsan_handle_type_mismatch_v1 handler
Date: Tue, 10 Oct 2017 00:06:03 -0700	[thread overview]
Message-ID: <1507619163-22943-1-git-send-email-psodagud@codeaurora.org> (raw)
In-Reply-To: <4ee8e077-feb4-c2ff-5eca-ef06012d34b3@virtuozzo.com>

In LLVM __ubsan_handle_type_mismatch handler is renamed to
 __ubsan_handle_type_mismatch_v1. Add support for
__ubsan_handle_type_mismatch_v1 handler to avoid compilation
issues with latest llvm tool chain. Also keeping
__ubsan_handle_type_mismatch handler for backward compatibility.

Signed-off-by: Prasad Sodagudi <psodagud@codeaurora.org>
---
 lib/ubsan.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/lib/ubsan.c b/lib/ubsan.c
index fb0409d..9baf17d 100644
--- a/lib/ubsan.c
+++ b/lib/ubsan.c
@@ -328,6 +328,14 @@ void __ubsan_handle_type_mismatch(struct type_mismatch_data *data,
 }
 EXPORT_SYMBOL(__ubsan_handle_type_mismatch);
 
+void __ubsan_handle_type_mismatch_v1(struct type_mismatch_data *data,
+				unsigned long ptr)
+{
+	__ubsan_handle_type_mismatch(data, ptr);
+}
+EXPORT_SYMBOL(__ubsan_handle_type_mismatch_v1);
+
+
 void __ubsan_handle_nonnull_return(struct nonnull_return_data *data)
 {
 	unsigned long flags;
-- 
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
a Linux Foundation Collaborative Project

  reply	other threads:[~2017-10-10  7:06 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-06  2:29 __ubsan_handle_type_mismatch converted to __ubsan_handle_type_mismatch_v1 Sodagudi Prasad
2017-10-06  8:45 ` Andrey Ryabinin
2017-10-10  7:06   ` Prasad Sodagudi [this message]
2017-10-10 12:22     ` [PATCH] UBSAN: Add __ubsan_handle_type_mismatch_v1 handler Andrey Ryabinin

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=1507619163-22943-1-git-send-email-psodagud@codeaurora.org \
    --to=psodagud@codeaurora.org \
    --cc=akpm@linux-foundation.org \
    --cc=aryabinin@virtuozzo.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=nicolas.iooss_linux@m4x.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome