SMALL IRISH village at the foot of the Galtee mountains in Tipperary is now confidently expecting a visit from President Reagan during his four-year term of office. "Mr. Reagan can be sure of one thing in Ballyporeen, and that is 100,000 welcomes (a Cead Mile Failte, as they say it in the Gaelic)," says Brigid Casey, a local housewife loading her trolley in the supermarket.

The excitement began two months ago when genealogical researchers from London, Dublin and the U.S. arrived in the village and holed up in John O'Farrell's pub. They told astonished customers that they were in search of President Reagan's ancestors and the Reagan family homestead. On inauguration day, O'Farrell's was renamed the Ronald Reagan Pub.

One villager said: "At a stroke we seem to be on the map of the world." Soon journalists, and especially photographers, were arriving from all the leading Irish papers, wanting to photograph the "family homestead." Camera equipment was trailed up muddy lanes, and small farmers who never read anything but the local newspaper, the Cork Examiner, with its good horse racing tips, found themselves being interviewed by media from far-away places they had barely heard about. Tumbledown cow houses were inspected and their owners questioned. But there is nothing standing now, not even a cow house, that would have existed when the president's ancestors lived in the area about 130 years ago. Small farmers in those days lived in little houses made of mud and clippings of ash trees, with a hole in the roof to let out the smoke from the turf fire.

The oldest locally born person in the area is Nora Hynes, 85, who has a clear recollection of the Reagans. She sat propped up with pillows in an old-persons home and recalled: "The Reagans were farming stock pure and simple with no notions about themselves at all. They sold eggs on Tuesdays and they would come into town and tie up the pony and trap in my parents' yard."

Eleven of America's 40 presidents have the Protestant forebearers from Ulster. Until now, only one, Kennedy, came from Southern Irish stock. Now Reagan makes it two.

The story began not with the arrival of the visiting media on Ballyporeen main street, which is so broad as Pennsylvania Avenue opposite the White House, but at St. George's Roman Catholic Cathedral, Southwark in South London. The records show that on Oct. 31, 1852, Michael O'Reagan of Dollis, Ballyporeen, County Tipperary, Ireland, married Katherine Mulcahy. Michael was the great-grandfather of the president.

In the register Michael signed himself O'Reagan and the best man, his elder brother, had his name recorded as Reagan, the name being written in by the priest who preformed the ceremony. With an illiterate it was the custom for the priest to sign on his behalf. Nor was it surprising that the younger son could write but the older one could not. In the Ireland of those days it was usual for the eldest son to work on the farm from an early age while the younger ones were given an education.

The name in Ireland is always spelled Regan, never Reagan. Bank managers, doctors, lawyers and other pillars of the local community are always pronounced Reegan. Farm laborers and unskilled workers are pronounced Raygan, more often than not, the same way the president and other Americans pronounce it.

It is too early to say yet what the impact of Ronald Reagan in the White House will be on Ballyporeen. The village, built by the English landlord Lord Kingston, has a reserve more reminiscent of England than Ireland. They are immensely proud of distinguished sons. At the filling station the attendant told me: "We used say that the Hollywood actor Pat O'Brien came from here. Now we have Ronald Reagan as well. It will take any other Irish village our size a long time to beat that."

The ancestral search has now moved out of the village to a wide stretch of countryside beneath the mountains called Skeheenarinky. It is believed that at least one of the four sisters of the president's great-grandfather married in this area. Research is likely to produce some cousin of the president in one or more of the small farms on the side of the Galtee mountains famous for its cheese.

Unfortunately there are not any Regans, O'Regans, or Reagans living in the area anymore. The name has died out. Though they don't talk of anybody "dying" in Ballyporeen. People have "gone to their eternal reward" and that's where the local Reagans have all gone, making research difficult.

A spokesman for the Irish government in Dublin agreed that there was a great deal of research still to be done. The government is not involved. Said the spokesman: "If President Reagan was to ask us to trace his relations we would get the resources of the state behind the job and -- given the evidence already available -- I'm sure we would be successful. But President Reagan has not asked us to find his ancestors."

What makes the official spokesman so confident is that both President Kennedy's and President Nixon's ancestors were successfully traced. "When we started tracing the Nixons we had very hazy stuff to go on," the government man added.

President Nixon's mother's ancestors were traced to a cemetery at Timahoe, a village beside a vast peat (the Irish call it turf) bog in the center of the country and to where they moved from Ulster during one of the persecutions. The overgrown cemetery was taken in hand by the government. Straying cows were put out, the fences mended, and a team of landscape architects and gardeners laid out trees and walks. A stonemason carved the names Milhous on a tombstone. All the names had been rubbed off the tombstones by cows rubbing their backsides.

President Kennedy's ancestral home was not given such lavish treatment, but roads were widened, trees planted, and the old mud farmyard covered over with cement.

Local politicians are hoping for improvements at least on a similar scale before President Reagan comes to Ballyporeen.The village people told me that they did not want too much fuss. But they would be eternally grateful if the new-found Reagan links with the place resulted in holes in the roads being mended and the telephone system improved.

In the cemetery I met Michael O'Donoghue of Long Beach, Calif., who had traveled more than 100 miles in a rainstorm to see the village. He was photographing a gravestone -- the wrong Reagan as it turned out. But what really attracted him was the report in the local paper. The Nationalist, saying that a firm link has now been established between President Reagan and the 11th-century warrior-king of all Ireland, King Brian Boru.

"My, oh my, no American president could hope for better ancestry than that," said O'Donoghue as the rain dropped off his plastic hat.