Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758043AbcDLVS0 (ORCPT ); Tue, 12 Apr 2016 17:18:26 -0400 Received: from youngberry.canonical.com ([91.189.89.112]:51188 "EHLO youngberry.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933990AbcDLU7x (ORCPT ); Tue, 12 Apr 2016 16:59:53 -0400 From: Kamal Mostafa To: linux-kernel@vger.kernel.org, stable@vger.kernel.org, kernel-team@lists.ubuntu.com Cc: Arnd Bergmann , Jonathan Cameron , Kamal Mostafa Subject: [PATCH 3.19.y-ckt 19/56] iio: st_magn: always define ST_MAGN_TRIGGER_SET_STATE Date: Tue, 12 Apr 2016 13:58:37 -0700 Message-Id: <1460494754-32183-20-git-send-email-kamal@canonical.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1460494754-32183-1-git-send-email-kamal@canonical.com> References: <1460494754-32183-1-git-send-email-kamal@canonical.com> X-Extended-Stable: 3.19 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1622 Lines: 43 3.19.8-ckt19 -stable review patch. If anyone has any objections, please let me know. ---8<------------------------------------------------------------ From: Arnd Bergmann commit 9b090a98e95c2530ef0ce474e3b6218621b8ae25 upstream. 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") Acked-by: Denis Ciocca Signed-off-by: Jonathan Cameron Signed-off-by: Kamal Mostafa --- 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 7e81d00..bae6622 100644 --- a/drivers/iio/magnetometer/st_magn.h +++ b/drivers/iio/magnetometer/st_magn.h @@ -40,6 +40,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.4