Attention handler configuration file support

The default behavior of the attention handler can be overriden by
modifying the config file contents. The behavior can also be defined
by the associated build option. The default behavior remains
unchanged. The intent of this change is to allow other components to
change the attention handler behavior by updating the configuration file
and restarting the attention handler service.

Signed-off-by: Ben Tyner <ben.tyner@ibm.com>
Change-Id: I8f73004c926a3a070c5feb690ee5684429f922c5
diff --git a/attn/meson.build b/attn/meson.build
index 616890f..34ec50a 100644
--- a/attn/meson.build
+++ b/attn/meson.build
@@ -6,16 +6,20 @@
 # dependency to link gpiod support
 libgpiod = dependency('libgpiod', version : '>=1.4.1')
 
-# ENABLE_PHAL_TRUE used in attn_handler.service.in
+# get openpower-hw-diags build configuration
 attn_conf = configuration_data()
 
+# conditionally define ENABLE_PHAL_TRUE
 if (get_option('phal').enabled())
     attn_conf.set('ENABLE_PHAL_TRUE', '')
 else
     attn_conf.set('ENABLE_PHAL_TRUE', '#')
 endif
 
-# install systemd unit file
+# attention handler default config override
+attn_conf.set('ATTN_CONFIG', get_option('attn_config'))
+
+# install attention handler unit file
 configure_file(
     configuration: attn_conf,
     input: 'attn_handler.service.in',
@@ -25,6 +29,15 @@
         dependency('systemd').get_variable(pkgconfig: 'systemdsystemunitdir')
 )
 
+# install attention handler config file
+configure_file(
+    configuration: attn_conf,
+    input: 'attn_config.in',
+    output: 'attn_config',
+    install: true,
+    install_dir: join_paths(get_option('sysconfdir'), 'default')
+)
+
 # Source files.
 attn_src = files(
     'attention.cpp',