drivers: adc: make a copy of sequence struct

We should not be storing the sequence pointer, as
adc_read_async() returns immediately. The memory could
be heap allocated, or on a call stack. Make a copy of
it instead.

Fixes: #15039

Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
diff --git a/drivers/adc/adc_sam_afec.c b/drivers/adc/adc_sam_afec.c
index 3e13902..f9ec474 100644
--- a/drivers/adc/adc_sam_afec.c
+++ b/drivers/adc/adc_sam_afec.c
@@ -150,7 +150,7 @@
 {
 	struct adc_sam_data *data = CONTAINER_OF(ctx, struct adc_sam_data, ctx);
 
-	data->channels = ctx->sequence->channels;
+	data->channels = ctx->sequence.channels;
 
 	adc_sam_start_conversion(data->dev);
 }