The initial meaning is a function that takes functions as its argument; that is, a function whose domain is a set of functions. This was how the word was used initially, in the calculus of variations, where the integrand to be minimised should be a functional, applied to an as-yet unknown function satisfying only some boundary conditions, and differentiability conditions.
This usage still applies in that context, in many part of physics, and in computer science, where in lambda calculus and functional programming a higher-order function is one that accepts a function and returns some value.
It also applies when one talks about a functional equation, meaning an equation between functionals: an equation F = G between functionals can be read as an 'equation to solve', with solutions being themselves functions. In such equations there may be several sets of variable unknowns, as when it is said that an additive function f is one satisfying the functional equation f(x+y) = f(x) + f(y).
The secondary usage in the compound linear functional arises from functional analysis. While in the foundational period of functional analysis from 1900-1920, it was largely the study of vector spaces such as the Lp spaces that are function spaces, the later axiomatic approach made no such assumption. The name linear functional, however, was carried over and applied to the dual space construction, in the general case.