the geologists that influenced Darwin's thinking with their work were Lyell and Hutton , together both are saying that the earth is millions of years old whereas people back then used to think that according to the bible earth was just about 6000 years old if you track the generations or the genealogies. of course not every single generation is noted on the bible. also the discovery of fossils suggests evolution,
in addition people used to think that earth hasn't changed neither its life since the moment of creation
in short, the ideas were that earth natural processes operate very slowly, thus the earth must be millions of years old. that made Darwin wonder "if the earth is very old and changing, would life change as well over time? also he realized that life evolvells with such a great amount of time