Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758170AbcC2U2V (ORCPT ); Tue, 29 Mar 2016 16:28:21 -0400 Received: from mout.kundenserver.de ([212.227.126.134]:63587 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758029AbcC2U2T (ORCPT ); Tue, 29 Mar 2016 16:28:19 -0400 From: Arnd Bergmann To: Jonathan Cameron Cc: Arnd Bergmann , Hartmut Knaack , Lars-Peter Clausen , Peter Meerwald , Giuseppe Barba , Denis Ciocca , Linus Walleij , linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] iio: st_magn: always define ST_MAGN_TRIGGER_SET_STATE Date: Tue, 29 Mar 2016 22:27:27 +0200 Message-Id: <1459283273-1059478-1-git-send-email-arnd@arndb.de> X-Mailer: git-send-email 2.7.0 X-Provags-ID: V03:K0:5+7wpdi0NdrJ1dNlPg0M+PCUVzyehThyWWOG1UBKdtbnTog5Ym3 c9pgAKTHs3NjmYPdxVh5EKSwmFtvR8gMMyuY5n1+PYfKziKDF6FNBhblHzklZvH6ppep6zq I3vq+yZvIkUGCsrIvWYZwEhQdy0gF9UPLgOzgqcqSMq5O8o+Ipu9dZPHKvRKd3pvdzGxBSn +4KXqT7eItLXxLFSaCxTA== X-UI-Out-Filterresults: notjunk:1;V01:K0:lSAJNJ1iXXA=:ICPFrYgyMV4SLxkNzAHFiB TAY/7iY0AYcG5wfmsXWdAGYMdlB6ubUNxbMIYf/WUyIXfpfV2QAubKumrGrN84Z3Z9tUYhVjt kGxIwBrfqt4FhRITYFX+gyrzREJIPHI1bKZgWuCnQJ6R5NvFJRLJ2dAFp80RCgTmyzliXKLTU Jbu3VN9Y3oZNZ5zo3wSPhIoX912vJN5L2YHE36a4Zpt31srd8r0s3mJZ/0TZBej6otc1xhClZ xRhyIF3O55HM96FnU7WyUHTY3QKdwa0iwIJD3agTDaRSX651K2eF2K7V2XnOe/4dvwjLP3tRk NtQeVP2r3kQhsHJPfS0ANEI8J7NxUmOz0Y2Omj+2ELk3HIM3g8MnW89W9X7OVZuhW1ul81WEw imInMSXog+3SHcIXFxqnJ/9pEEAnsKS9buBxZsQylhkGa8y4uIc235G2Hv0o6dCboqMUvksGp t885uVfCpIqZag2f4rysQlZkwLjOLtlyYd3aHwIgDV5XT0Gqt+KbbKtwhU+Kz7iWa+tJkLU1Y K+0ueb3b3tw4Bwhx7MqwITwRkunWy6RK+IXVPiyXaKrSmzvsop8e4ibKNYqgT2IOty+FYPcb2 387WfJjEemFUkPH61TMqTx1CskKNV/yYVLkbIO3ZOY0qt0QuiC+Ueb5H0JqBXAjgVY+cwJlUH oFIcU4ibVQMgJg79wKp5DPlxIzubV1cN5FYuJyLfmMt1VSy5AqWHlzfaDQ6HPZB7Q9q4= Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1235 Lines: 32 When CONFIG_IIO_TRIGGER is enabled but CONFIG_IIO_BUFFER is not, we get a build error in the st_magn driver: drivers/iio/magnetometer/st_magn_core.c:573:23: error: 'ST_MAGN_TRIGGER_SET_STATE' undeclared here (not in a function) .set_trigger_state = ST_MAGN_TRIGGER_SET_STATE, ^~~~~~~~~~~~~~~~~~~~~~~~~ Apparently, this ST_MAGN_TRIGGER_SET_STATE macro was meant to be set to NULL when the definition is not available because st_magn_buffer.c is not compiled, but the alternative definition was not included in the original patch. This adds it. Signed-off-by: Arnd Bergmann Fixes: 74f5683f35fe ("iio: st_magn: Add irq trigger handling") --- drivers/iio/magnetometer/st_magn.h | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/iio/magnetometer/st_magn.h b/drivers/iio/magnetometer/st_magn.h index 06a4d9c35581..9daca4681922 100644 --- a/drivers/iio/magnetometer/st_magn.h +++ b/drivers/iio/magnetometer/st_magn.h @@ -44,6 +44,7 @@ static inline int st_magn_allocate_ring(struct iio_dev *indio_dev) static inline void st_magn_deallocate_ring(struct iio_dev *indio_dev) { } +#define ST_MAGN_TRIGGER_SET_STATE NULL #endif /* CONFIG_IIO_BUFFER */ #endif /* ST_MAGN_H */ -- 2.7.0